Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

fix #387 #455

Closed
wants to merge 4 commits into from
Closed

fix #387 #455

wants to merge 4 commits into from

Conversation

schferbe
Copy link

Checklist

  • [X ] Tick to sign-off your agreement to the Developer Certificate of Origin (DCO) 1.1
  • Added tests for code changes or test/build only changes
  • Updated the change log file (CHANGES.md|CHANGELOG.md) or test/build only changes
  • Completed the PR template below:

Description

Fixes #387

Approach

added auth parameters to login request

Schema & API Changes

No change

Security and Privacy

No change

Testing

No new tests because specific CouchDB configuration would be needed.

Monitoring and Logging

No change

@ricellis
Copy link
Member

Just an FYI that this problem was recently corrected for CouchDB 3, so should be going away server-side from that release.

@schferbe
Copy link
Author

Thank you! That is good to know. CouchDB doesn't seem to release on a weekly base though so it might be nice to have it here as well.

@bessbd
Copy link
Contributor

bessbd commented Nov 26, 2019

Hi @schferbe ,
Thank you for the patch! For us to merge this change, we’d need more tests so that we can be confident it does not break other things accidentally and that this would not get removed accidentally.
Looking at https://lists.apache.org/thread.html/5c81b88c60ce81506d650893c61cd9228f4c1c0fab777e55a4f5c27a@%3Cdev.couchdb.apache.org%3E , it seems couchdb3 is very close to a release.
Can you wait until couchdb3 is released or would you like to put more efforts into having automated tests for this change?

Also, have you tried using basic auth when require_valid_user is enabled as a workaround?

@schferbe
Copy link
Author

Now CouchDB 3 is released in their own apt repository. I will close this PR.

@schferbe schferbe closed this Feb 26, 2020
@vlad88sv
Copy link

I just ran into this situation, and the fix provided worked really fine!

Any chance this could still get merged? (pretty please?)

@ricellis
Copy link
Member

You can workaround require_valid_user blocking the _session endpoint in CouchDB 2.x by making python-cloudant use basic auth instead. This is done by initializing with the use_basic_auth=True kwarg e.g.

CouchDB(user, pass, url=url, use_basic_auth=True)

@vlad88sv
Copy link

Thank you! that parameter worked fine!

rjcorwin referenced this pull request in Tangerine-Community/Tangerine Dec 10, 2020
…uses require_valid_user which is not compatible with python cloudant client default auth of Cookies. Suggested solution: https://github.com/cloudant/python-cloudant/pull/455\#issuecomment-680789311
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Authentication doesn't work with CouchDB if option require_valid_user is enabled
4 participants