UI: unable to login to webui if user and project belongs to different domains

Bug #1727809 reported by Senthilnathan Murugappan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R3.2
Fix Committed
High
Biswajit Mandal
R4.0
Fix Committed
High
Biswajit Mandal
R4.1
Fix Committed
High
Biswajit Mandal
Trunk
Fix Committed
High
Biswajit Mandal

Bug Description

unable to login to webui as non-admin user if user and project belongs to different domains

Creds:
username: msenthil
password: c0ntrail123
role: _member_
user-domain-name: Default
project-name: msenthil-test
project-domain-name: JNPR

Traces form webui logs:

10/25/2017 09:41:15 AM - debug: After V3 Successful auth def_token:{"token":{"issued_at":"2017-10-25T04:11:14.957223Z","audit_ids":["dx7cvqjeTjGdGaK5A9KmAQ"],"methods":["password"],"expires_at":"2017-10-25T05:11:14.957188Z","user":{"domain":{"id":"default","name":"Default"},"id":"018531ef07574d1386139c3de2fa8cf2","name":"msenthil"}}}
10/25/2017 09:41:15 AM - error: URL [http://10.183.10.10:5000/v3/auth/tokens] returned error [{"error":{"message":"The request you have made requires authentication.","code":401,"title":"Unauthorized"}}]
TypeError: Failed to parse JSON body: Cannot read property 'msenthil-test' of undefined
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:2037:54
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:1873:13
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:1831:13
    at /usr/lib64/node_modules/async/lib/async.js:254:17
    at done (/usr/lib64/node_modules/async/lib/async.js:129:15)
    at /usr/lib64/node_modules/async/lib/async.js:32:16
    at /usr/lib64/node_modules/async/lib/async.js:251:21
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:1806:9
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:737:13
    at APIServer.retryMakeCall (/usr/src/contrail/contrail-web-core/src/serverroot/common/rest.api.js:209:5)
10/25/2017 09:41:15 AM - error: URL [http://10.183.10.10:5000/v3/auth/tokens] returned error [{}]

/usr/lib64/node_modules/async/lib/async.js:30
            if (called) throw new Error("Callback was already called.");
                              ^
Error: Callback was already called.
    at /usr/lib64/node_modules/async/lib/async.js:30:31
    at /usr/lib64/node_modules/async/lib/async.js:251:21
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:1806:9
    at /usr/src/contrail/contrail-web-core/src/serverroot/orchestration/plugins/openstack/keystone.api.js:737:13
    at APIServer.retryMakeCall (/usr/src/contrail/contrail-web-core/src/serverroot/common/rest.api.js:209:5)
    at Request.<anonymous> (/usr/src/contrail/contrail-web-core/src/serverroot/common/rest.api.js:333:18)
    at Request.emit (events.js:98:17)
    at Request.mixin._fireError (/usr/lib64/node_modules/restler/lib/restler.js:204:10)
    at /usr/lib64/node_modules/restler/lib/restler.js:155:20
    at IncomingMessage.parsers.json (/usr/lib64/node_modules/restler/lib/restler.js:399:9)
10/25/2017 09:41:15 AM - debug: The worker #15 has disconnected.

Tags: ui
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/36885
Submitter: Biswajit Mandal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R4.1

Review in progress for https://review.opencontrail.org/36948
Submitter: Biswajit Mandal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/36885
Committed: http://github.com/Juniper/contrail-web-core/commit/a0cfcd527839d99ad12a64cb605bc3f9af7170a4
Submitter: Zuul (<email address hidden>)
Branch: master

commit a0cfcd527839d99ad12a64cb605bc3f9af7170a4
Author: Biswajit Mandal <email address hidden>
Date: Thu Oct 26 15:09:45 2017 -0700

Unable to login to webui if user and project belongs to different domains

Issue was while authenticating with keystone v3 in post data we used to use
domain as the user logged in, in stead of that we need to send the domain where
the project exists.

Now in stead of using project:name / domain:name in scope structure, using the
project:id, thus removing the need for domainname specify.

Change-Id: I5c4dcab8d9645dbabb5bdde54d99858d62e295c3
Closes-Bug: #1727809

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Reviewed: https://review.opencontrail.org/36948
Committed: http://github.com/Juniper/contrail-web-core/commit/3f1b4902dfe43de16a5ab3882d9e56f78d2372fd
Submitter: Zuul (<email address hidden>)
Branch: R4.1

commit 3f1b4902dfe43de16a5ab3882d9e56f78d2372fd
Author: Biswajit Mandal <email address hidden>
Date: Thu Oct 26 15:09:45 2017 -0700

Unable to login to webui if user and project belongs to different domains

Issue was while authenticating with keystone v3 in post data we used to use
domain as the user logged in, in stead of that we need to send the domain where
the project exists.

Now in stead of using project:name / domain:name in scope structure, using the
project:id, thus removing the need for domainname specify.

Change-Id: I5c4dcab8d9645dbabb5bdde54d99858d62e295c3
Closes-Bug: #1727809

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R4.0

Review in progress for https://review.opencontrail.org/39506
Submitter: Biswajit Mandal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R3.2

Review in progress for https://review.opencontrail.org/39507
Submitter: Biswajit Mandal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/39507
Committed: http://github.com/Juniper/contrail-web-core/commit/7895b5c63b10d13deecbe21f1571e6fb5a13d1c6
Submitter: Zuul (<email address hidden>)
Branch: R3.2

commit 7895b5c63b10d13deecbe21f1571e6fb5a13d1c6
Author: Biswajit Mandal <email address hidden>
Date: Thu Oct 26 15:09:45 2017 -0700

Unable to login to webui if user and project belongs to different domains

Issue was while authenticating with keystone v3 in post data we used to use
domain as the user logged in, in stead of that we need to send the domain where
the project exists.

Now in stead of using project:name / domain:name in scope structure, using the
project:id, thus removing the need for domainname specify.

Change-Id: I5c4dcab8d9645dbabb5bdde54d99858d62e295c3
Closes-Bug: #1727809
(cherry picked from commit 3f1b4902dfe43de16a5ab3882d9e56f78d2372fd)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Reviewed: https://review.opencontrail.org/39506
Committed: http://github.com/Juniper/contrail-web-core/commit/d546c246a23ad37d32bb002332f8f41caa7ff3dc
Submitter: Zuul (<email address hidden>)
Branch: R4.0

commit d546c246a23ad37d32bb002332f8f41caa7ff3dc
Author: Biswajit Mandal <email address hidden>
Date: Thu Oct 26 15:09:45 2017 -0700

Unable to login to webui if user and project belongs to different domains

Issue was while authenticating with keystone v3 in post data we used to use
domain as the user logged in, in stead of that we need to send the domain where
the project exists.

Now in stead of using project:name / domain:name in scope structure, using the
project:id, thus removing the need for domainname specify.

Change-Id: I5c4dcab8d9645dbabb5bdde54d99858d62e295c3
Closes-Bug: #1727809
(cherry picked from commit 3f1b4902dfe43de16a5ab3882d9e56f78d2372fd)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.