问题标签 [oauth-1.0a]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
1688 浏览

c# - 在 C# 中通过 OAuth 1.0 连接到 WordPress 时,为什么我的 OAuth 签名不匹配?

我正在尝试完成 OAuth 1.0 身份验证过程的第一步并检索未经授权的请求令牌。

我不断收到来自 WordPress 的 401 OAuth 签名不匹配错误。我知道问题出在我散列签名的方式上,因为当我使用 Postman 时,我计算的签名与 Postman 计算的签名不同。我也可以通过 Postman 成功检索和未经授权的请求令牌。

我在计算哈希时哪里出错了?我正在使用 HMAC-SHA1。

0 投票
0 回答
116 浏览

oauth - Oauth 1.0 compatiability with Amazon Oauth 2.0

I'm currently working with PhpoAuthLib Library Here

and i'm working with trying to integrate it into an Alexa skill for the Amazon echo. I have pretty much got the entire workflow and I am stumped on the last step as Amazon's error reporting is less than helpful and instead of giving a specific detail of whats going wrong, I get a generic 'the account could not be linked', error. Amazon developer forums are just as useless as the moderators seem to just direct you to the same documentation which I've read 10 times already to no success.

I've been using this video as reference and from what he says it sounds like it's possible to link an oauth 1.0 service to alexa, but im falling at the last hurdle. (at the 4:40 mark)

It's a pretty specific issue but maybe someone with some in depth knowledge of the two versions of oauth could help point out what would need to be handed back to Amazon to successfully link to the 2.0 service they have.

For some context, I'm trying to link an alexa skill to a users Etsy account, allowing them to access details of their account through voice control on the echo. Etsy Oauth is still 1.0, and amazon's account linking system is oauth 2.0.

0 投票
2 回答
1122 浏览

php - 在 PHP 中实现的 Auth 1.0a 中的无效签名

它的响应是:HTTP Status 401 - Invalid signature for signature method HMAC-SHA1

您能帮忙解决生成签名的问题吗?

0 投票
1 回答
1907 浏览

php - Woocommerce rest api 在发布请求时签名无效(错误 401)

我正在为 woocommerce 商店开发 Ionic 2 项目。我在我的应用程序中使用Woocommerce REST API并使用Postman Chrome App使用 OAuth-1.0 测试 API 。我通过 GET 请求得到了正确的响应,但对于 POST 请求,我收到了签名不匹配的错误,如:

0 投票
0 回答
289 浏览

python - Rauth 或替代 python 3 库是否可以实现 2 腿 oauth?

我一直在寻找一种在 python 3 中实现 2 legged oauth 的方法,以使用 brightcloud api。他们在此处提供了几个使用 java、php、ruby、.NET C# 的代码示例:https ://bcws.brightcloud.com/code-samples.php 。我尝试按照相同的逻辑将 java 示例转换为 python,但是,我对 python 比较陌生,很快就陷入困境。

我尝试使用 rauth 来实现,但是,基本设置使用了一个 request_token_url,它不是由 brightcloud 提供的。我还尝试使用基于此答案的以下代码实现 - 如何在 python 中使用 2-legged oauth2 发送 POST?

这行有问题: u = urllib.request.urlopen(request.to_url())

这会生成以下回溯:

回溯(最近一次调用):文件“bright.py”,第 37 行,在 u = urllib.request.urlopen(request.to_url()) 文件“/usr/lib/python3.5/urllib/request.py”中,第 163 行,在 urlopen 返回 opener.open(url, data, timeout) 文件“/usr/lib/python3.5/urllib/request.py”,第 472 行,在打开响应 = meth(req, response) 文件“ /usr/lib/python3.5/urllib/request.py”,第 582 行,在 http_response 'http'、请求、响应、代码、msg、hdrs)文件“/usr/lib/python3.5/urllib/request. py”,第 510 行,错误返回 self._call_chain(*args) 文件“/usr/lib/python3.5/urllib/request.py”,第 444 行,在 _call_chain 结果 = func(*args) 文件“/usr /lib/python3.5/urllib/request.py”,第 590 行,在 >http_error_default 中引发 HTTPError(req.full_url,代码,味精,hdrs,fp)urllib.error.HTTPError:HTTP错误401:未经授权

任何帮助将非常感激。

0 投票
0 回答
491 浏览

alamofire - 如何通过 Oauth1 获取方法使用 Alamofire

我已经安装了库 Alamofire,我想使用 Get Request Method 来获取数据 API

像这样的代码:

我得到了这样的错误

我认为使用 Alamofire Oauth1 访问 API 的代码有问题。那么如何将 Alamofire 与 Oauth1 获取方法一起使用

0 投票
1 回答
160 浏览

ruby-on-rails - 使用 Ember.js 和 Rails 进行 Twitter 身份验证

我正在使用 Torii 和 ember-simple-auth 在我的前端管理身份验证,并在我的服务器上使用 Knock 和 Omniauth-twitter。我用 Facebook 没问题,但 Twitter 使用 Oauth1.0,我很难弄清楚流程。

这是我的 Torii 配置:

我的路线或控制器:

一个新窗口正在打开,我可以使用我的 Twitter 帐户登录。我的服务器进行身份验证/注册,但我不知道如何关闭这个新窗口并将令牌发送到我的前面。我的流程完全错误吗?还是我错过了什么?我跟着这个教程,但我想知道它是不是有点过时了

0 投票
1 回答
464 浏览

java - 使用 oauth 保护的 SOAP Web 服务

有谁知道我如何添加消费者密钥和消费者秘密来使用由 OAuth1.0a 保护的 SOAP Web 服务?在调用肥皂服务之前,我正在尝试将此密钥和秘密添加到肥皂标题中。

0 投票
1 回答
23 浏览

html - OAuth 1.0 服务器查看哪些参数?

我正在使用 OAuth 1.0 签署通过 http POST 发送的请求。

我的问题是,接收有效负载的服务器是根据表单中发送的所有字段生成签名,还是只根据它关心的字段生成签名?

我正在使用一个为自己的目的插入一些额外字段的 Web 框架,我想知道这些是否会干扰服务器上的 OAuth 签名生成过程?

0 投票
1 回答
961 浏览

angular - Angular 4 和 Woocommerce API。Http GET 有效,但 http POST 无效

我正在尝试通过 HTTP POST 方法通过 Woocommerce API 添加产品。

这是授权outh1.0a

这是一个获取产品并且有效的功能

这是一个 POST 功能不起作用

我在 Postman 和 POST 请求中进行了测试,但如果我通过 Angular Http POST 发送请求,我会收到错误消息:{"errors":[{"code":"woocommerce_api_authentication_error","message":"Invalid Signature - provided signature does not match"}]}

有什么问题?

POST 标头

获取标头