summaryrefslogtreecommitdiff
path: root/src/store/modules/Authentication
AgeCommit message (Collapse)AuthorFilesLines
2020-07-22Add check if password change required at LoginYoshie Muranaka1-0/+6
After successfully authenticating on the Login page, check /redfish/v1/AccountService/Accounts/${username} endpoint for the PasswordChangeRequired property to see whether or not the password is expired. If the password is expired, then navigate to the Change password page, if the password isn't expired navigate to the Overview page. After successfully changing an expired password, navigate to the Overview page. Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com> Change-Id: I32de5f71bcfcbe4099c2953a31c05ba0ebe670bc
2020-06-17Profile settings pageSukanya Pandey1-0/+1
-To set the profile by setting password. -This commit adds a profile page which allows the user to change their password. In the future, the profile page will also contain user settings like language and timezone. The API called to change the user's password is '/redfish/v1/AccountService/Accounts/<userName>' Signed-off-by: Sukanya Pandey <sukapan1@in.ibm.com> Change-Id: Ie54a54beff8c85bc9ac5af21c35edc481b34cf44
2020-05-06Add XSRF token to websocket connectionYoshie Muranaka1-1/+2
Resolves HTTP authentication failure when attempting to make a websocket connection. Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com> Change-Id: Ie833f1cd281dd3b7124ac798eb5318b24df0ed8f
2020-03-13Fix accessibility violations and use b-form-groupDerick Montague1-2/+3
- Update authError to be set to false in order to hide the error message when the user logs in. This is needed if the user name or password are incorrect multiple times. If it is not hidden between login attempts, the user will only be notified on the first attempt. - Use the b-form-group component for consistency. - Add id attributes to the required field error messages so that the error can be added to the input field's aria-describedby attribute Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: I86902cc2c85b3bbf156c2920ec2031ee4dccd2ef
2020-02-14Clear application state on logoutDerick Montague1-2/+3
Remove the authError state property from the logout mutation since the the authError would not be in the true state after a successful login. Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: Ibfe8b07c4e9e37dfab4435596c12e9a36556a714
2020-01-31Update local user layout and stylesYoshie Muranaka1-12/+5
Resubmitting after reverted–original commit here https://gerrit.openbmc-project.xyz/c/openbmc/webui-vue/+/28790 - Add BVConfig plugin to modify boostrap component defaults - Add vuelidate - Add package and basic validations to user form - Add all user form validations - Add checks for edit user - Create VuelidateMixin for shared methods - Update Login to use Vuelidate Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com> Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: Ib50ee4d1fb5f14637c9460e77f0682869a86ac8a
2020-01-29Add login form validationDerick Montague1-1/+4
- Sending incorrect credentials returns a 401 and we don't want the page to redirect if we are trying to login. Wrapped the redirect in an if block. - Returning a promise used by the logout action, which is needed when not redirecting the page. Didn't add to the if block since other errors that use the router to redirect will need the Promise returned also, e.g. 403. Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: I6db706ef7c71ed13baed95dc4264e6ae11d13ad3
2020-01-27Add singlequote override and fix filesDerick Montague1-16/+16
Based on phosphor-webui and JavaScript common practices we are setting ESLint to required single quote for JS files and double quote for SCSS files. This commit adds the ESLint override to the prettier rules and runs the npm lint script that fixes the files that violate the rule. Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: I50cba77b2d0797595ce94258029608efa8665005
2020-01-27Add cookie based login authenticationYoshie Muranaka1-19/+13
- Changed POST request data structure to match backend requirements for set-cookie in response header - Added withCredentials property to default axios config - Modifying proxied response to remove 'Secure' flag so browser can create Cookie while running locally - Add logout api request - Add js-cookie package to manage browser cookies - Update the babel preset config to include useBuiltIns, which resolves MIME type errors when overlaying - Disable vue-router history mode to use routher hash mode to resolves 404 errors when refreshing certain pages. This is expected behavior with history mode enabled. Server configuration changes are required to support HTML5 history mode: https://router.vuejs.org/guide/essentials/history-mode.html#example-server-configurations Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com> Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: I5d43f36ef546962474b6cc8fff89564f29048fde
2020-01-23Add login and logout functionalityDerick Montague1-0/+56
- Add AuthenticationStore - Add ability to login and logout - Add route navigation guard - Add login styles - Add temporary authentication for api call - Add Login directory - Add index.js In order to login a .env.development.local file that contains BASE_URL="https://<ip address> or <FQDN>" Signed-off-by: Derick Montague <derick.montague@ibm.com> Change-Id: I88b93e287e66f4bae82a1ec2934cdef12d78264e