PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Monday, September 5, 2022

[FIXED] How to decode PHP serialized Redis response with Golang

 September 05, 2022     go, php, redis, serialization     No comments   

Issue

I have a problem with my Redis db, it is encoded with PHP serialized protocol but I don't how I can decode this data using Golang, is there something like JSON Unmarshall/Marshall for this?


Solution

To read such data in your Go program you will have to reimplement unserialize PHP function in Go. I doubt it is an easy task though.

A better solution would be to use a portable format to store data in Redis, such as JSON or Google Protobuf.



Answered By - kostya
Answer Checked By - Cary Denson (PHPFixing Admin)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing