Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Cannot upload in HTTPS with OAuth #5118

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 5 comments
Closed

Cannot upload in HTTPS with OAuth #5118

openstreetmap-trac opened this issue Jul 23, 2021 · 5 comments

Comments

@openstreetmap-trac
Copy link

Reporter: don-vip
[Submitted to the original trac issue database at 2.01pm, Monday, 10th February 2014]

Hi,

We have enabled HTTS support towards OSM API in latest JOSM (see #josm9710).

It works great with basic authentication, bur for some reason it fails with OAuth with HTTP 401:

INFO: PUT https://api.openstreetmap.org/api/0.6/changeset/create... 
INFO: OK
INFO: POST https://api.openstreetmap.org/api/0.6/changeset/20532333/upload... 
INFO: Authorization Required
ERROR: Error body: Couldn't authenticate you
ERROR: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401, Error Body=<Couldnt authenticate you>

It looks like there's a problem on server side ?

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 12.08am, Thursday, 13th February 2014]

Well the PUT worked, and that requires authentication.

@openstreetmap-trac
Copy link
Author

Author: stoecker
[Added to the original trac issue at 7.50am, Thursday, 13th February 2014]

BTW there is a typo: "Couldnt".

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 7.19pm, Thursday, 13th February 2014]

I have now tried (on my local instance) both Potlatch 2 and iD using oauth over https and both seem to be working.

My suspicion is that it's likely JOSM is somehow computing the oauth signature wrongly for POST requests over https.

@openstreetmap-trac
Copy link
Author

Author: don-vip
[Added to the original trac issue at 10.48pm, Thursday, 13th February 2014]

OK thanks for the test, we're investigating to see if would not be a bug in our OAuth Java library.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 5.49pm, Saturday, 15th February 2014]

It turned out this was a problem with our production environment that didn't occur in a test environment, and I think it should be fixed now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant