好的,所以我已经和这个战斗了一段时间。我正在尝试从 Android 应用程序对 LastFM 进行身份验证。
这个页面描述了我的基本攻击计划:http ://www.last.fm/api/mobileauth
sig = "api_key" + getString(R.string.lastfm_key) + "methodauth.getMobileSessionpassword" + pass + "username" + username +getString(R.string.last_api_secret);
String api_sig_md5 = md5(sig);
HttpPost hp_auth = new HttpPost("https://ws.audioscrobbler.com/2.0/"
+ "?method=auth.getMobileSession"
+ "&username=" + username
+ "&password=" + pass
+ "&api_key="
+ getString(R.string.lastfm_key)
+ "&api_sig=" + api_sig_md5);
我得到的回应是:
使用此方法时,您不得在查询字符串中发送密码。消息详细信息应仅在帖子正文中。
我认为我在遵循文档方面做得很好,但我坚持这一点。
提前致谢