Google Plus中的奇怪JSON响应 [英] Strange JSON response in Google Plus

查看:79
本文介绍了Google Plus中的奇怪JSON响应的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我在Google Plus中调试错误时(从Yahoo导入FB联系人时)我发现奇怪的JSON响应:

While I was debugging an error in Google Plus (while importing FB contacts from Yahoo) I've discovered strange JSON response:

)]}'

[[["er",,,,,500]
,["e",2,,,57]
],'45932b7d6d6dc08e']

它是JSONP的一些变体吗?让我想起了SQL注入......那么,开头的结束括号和引用的目的是什么?

Is it some variation of JSONP? Reminds me of an SQL injection rather... So, what's the purpose of the closing brackets and quote at the beginning?

推荐答案

它基本上是JSON,删除了空值,并在开头添加了垃圾以阻止XSRF。这里有一些解码它的PHP代码(来自我正在处理的非官方Google Plus API)。

It's basically JSON with nulls removed and the garbage added at the beginning to thwart XSRF. Here's some PHP code that will decode it (from an unofficial Google Plus API I'm working on).

https://github.com/jmstriegel/php.googleplusapi/blob/master/lib/GooglePlus/GoogleUtil.php

这篇关于Google Plus中的奇怪JSON响应的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆