News for hackers. Stuff that matters.
Re:Ask HN: What's the recommended method of adding authentic... by hundt on Tuesday January 16, 2018 @11:31AM (#16159374)
Do you recommend signing requests?
Re:Ask HN: What's the recommended method of adding authentic... by tptacek on Tuesday January 16, 2018 @11:39AM (#16159466)
No. The reason to sign requests is the same as the reason to support OAuth: so that the owner of the account can sign a request and give it to someone else to execute --- delegated authentication. Signed requests are finer-grained than OAuth is, but OAuth is much simpler and is the industry standard at this point. Don't do either thing until you absolutely need it, but then, start with OAuth.

Signed requests have burned a bunch of applications, more than have been burned by OAuth.

Re:Ask HN: What's the recommended method of adding authentic... by hundt on Tuesday January 16, 2018 @11:50AM (#16159574)
Thanks for the response!

My thinking was that you might sign requests so that a request that was intercepted or inadvertently logged would not contain sufficient credentials to authorize arbitrary other requests for the indefinite future. It sounds like you do not consider that a significant enough issue to justify the complexity involved.

Re:Ask HN: What's the recommended method of adding authentic... by dboreham on Tuesday January 16, 2018 @11:56AM (#16159654)
Good point: Credentials must not be logged. The easiest way to achieve this is to use HTTP basic auth for the token because web server infrastructure already knows not to log that, or a header OAuth2 style.
Re:Ask HN: What's the recommended method of adding authentic... by tptacek on Tuesday January 16, 2018 @11:55AM (#16159646)
No. You need to be securely using TLS anyways. Signed requests are hard to get right (Google "canonicalization vulnerabilities"). That's not a good tradeoff.
Re:Ask HN: What's the recommended method of adding authentic... by dboreham on Tuesday January 16, 2018 @11:52AM (#16159610)
Signed requests were also invented when the transport connection was in the clear: if the request were not signed then it could be modified in transit by an attacker. These days all sessions are encrypted (SSL/TLS) and so this concern doesn't exist (or doesn't exist if you trust the transport).
Re:Ask HN: What's the recommended method of adding authentic... by tptacek on Tuesday January 16, 2018 @11:54AM (#16159636)
The AWS API runs over TLS, and uses signed requests.
Re:Ask HN: What's the recommended method of adding authentic... by dboreham on Tuesday January 16, 2018 @10:51PM (#16165325)
Perhaps because it was originally designed for use without TLS? Request signing was pretty much ubiquitous 10 years ago.
Re:Ask HN: What's the recommended method of adding authentic... by Promarged on Wednesday January 17, 2018 @05:03AM (#16166776)
I'm not from Amazon but I'd guess they want to protect the request from being replayed inside their own systems.
Re:Ask HN: What's the recommended method of adding authentic... by sloxy on Wednesday January 17, 2018 @07:42AM (#16167409)
more likely it's so they don't have to have a more convoluted process where they call out to requesting service to verify RQ & all which that entails (on both sides).