doupu3211 2016-12-21 11:34 采纳率: 100%
浏览 262
已采纳

在golang中解码base64字符串

I have this string :

MTk6MTQ4MjMxOTY0MDo1NDU=

And i tried to decode it :

cookie_value = "MTk6MTQ4MjMxOTY0MDo1NDU="
sDec, _  := base64.StdEncoding.DecodeString(cookie_value)
Info.Println(sDec)

but it gives me that :

INFO: 2016/12/21 12:27:20 ApiRender.go:158: [49 57 58 49 52 56 50 51 49 57 54 52 48 58 53 52 53]

if you have any idea how to decode it properly

thanks and regards

  • 写回答

1条回答 默认 最新

  • dongshuo5101 2016-12-21 11:44
    关注

    It will be very hard:

    Info.Println(string(sDec))
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?