In this commit I created new signin routes which implement OAuth 2.0 single sign-on using the Windows Live REST API rather than the JavaScript API which we were using previously. To use the JavaScript API, the following external script had to be loaded from the js.live.net server in order to sign users in.
js.live.net/v5.0/wl.js
Using the Windows Live REST API over the JavaScript API has the following advantages:
Does not have to load the external Windows Live script from the external host js.live.net in order to sign users in.
Windows Live login page does not open in a pop-up window.
Does not use AJAX to send user data to the server.
Completely eliminates the need for a signin controller script.
Changelog:
Removed route signin.post, kept route signin.get, added routes signin.authenticate and signin.success in server/router/index.js.
Added route signout in server.router/index.js.
Added new signin paths /signin/authenticate and /signin/success to the open paths in server/middleware/wlauth.js.
Extracted the navbar markup into its own file navbar.html which is included in the layout default.html.
Added new navbar markup in navbar.html
Added custom navbar styles in public/css/styles.css
Added new signin page markup in server/views/signin.html.
Made the home route redirect to staff/staffHomePage for staff.
In this commit I created new signin routes which implement OAuth 2.0 single sign-on using the Windows Live REST API rather than the JavaScript API which we were using previously. To use the JavaScript API, the following external script had to be loaded from the
js.live.net
server in order to sign users in.Using the Windows Live REST API over the JavaScript API has the following advantages:
js.live.net
in order to sign users in.Changelog:
signin.post
, kept routesignin.get
, added routessignin.authenticate
andsignin.success
inserver/router/index.js
.signout
inserver.router/index.js
./signin/authenticate
and/signin/success
to the open paths inserver/middleware/wlauth.js
.navbar.html
which is included in the layoutdefault.html
.navbar.html
public/css/styles.css
server/views/signin.html
.home
route redirect tostaff/staffHomePage
for staff.