Auth
- Building Web Apps
- Create Users
- Authentication
- Authorization
- Passport
Create Users
Authentication
Authorization
Passport
Simple Authentication
- Passport-Local
- Passport Middleware
- Req.User….
Passport Middleware
Simple Authentication
- Passport.initialize()
- Passport.session()
- Express session
Passport User Functions
User Management in the Session
- passport.serializeUser()
- passport.deserializeUser()
- passport-local
Secured Routes
Real-time networking with NodeJS
What is WebSocket?
Full-duplex communication over TCP for web browsers and servers
WebSocket
- BI-Directional
- Persistent tunnel
- Proxy/Firewall friendly
- Standards based
WebSocket
Solves many bi-directional problems on the web
- Depends on modern browsers
- Relies on HTTP for handshake only
- Rely on libraries to simplify the raw features
What is Socket.io?
Enabling real-time apps in browser (and mobile)
Socket.io is an abstraction over different transports including Websockets
Effectively Signalr for NodeJS
Socket.io
Simplifies creating communications and multicasting in real-time
- Server and client libraries work together
- Works side-by-side with Express or other frameworks
- Works well with Angular, React too
Auth
By Shuhratbek Mamadaliyev
Auth
- 916