pouchdb-authentication, getSession() with different domain shows null
- Dominant language
- JavaScript
- Stars
- 17.6k
- Forks
- 1.5k
- PR merge metrics
- No merged PRs in 30d
Description
### Issue
I'm using **pouchdb-authentication** plugin to handle my couchdb authentication. The issue is when I try to login a valid user with different domains like front end domain: http://localhost:8080/login and backend domain: http://127.0.0.1:5984/mydb/ my getSession() function returns a null userCxt name: userCtx: {name: null, roles: []}. however when I try to login same user with same domains like front end domain: http://localhost:8080/login and backend domain: http://localhost:5984/mydb/ my getSession() function returns the user userCxt name: userCtx: {name:"testUser", roles: []}.
### Info
- Environment: browser
- Platform: Chrome
- Adapter: none
- Server: CouchDB
### Reproduce
To reproduce the issue:
- create a login form running on a domain different from the couchdb domain
- create the poucdb instance with http://127.0.0.1:5984/mydb/ or some other remote couchdb
- authenticate the user with pouchdb-authentication login function
- get the user session with pouchdb-authentcation getSession() function
Contributor guide
Assessment
This issue has not been assessed yet.