01:21:22  * pizthewizquit (Quit: 😴)
02:06:56  * emanresu404joined
02:13:28  * emanresu404quit (Ping timeout: 250 seconds)
02:39:09  * emanresu404joined
02:45:46  * emanresu404quit (Ping timeout: 256 seconds)
02:49:12  * mmitchelljoined
03:29:43  * prbcjoined
03:43:08  * prbcquit (Remote host closed the connection)
03:43:46  * prbcjoined
03:44:57  * prbcquit (Read error: Connection reset by peer)
03:45:22  * prbcjoined
03:58:44  * emanresu404joined
04:26:17  * prbcquit (Ping timeout: 264 seconds)
04:30:50  * prbcjoined
04:35:20  * prbcquit (Read error: Connection reset by peer)
04:36:10  * prbcjoined
04:37:29  * mmitchellquit (Remote host closed the connection)
05:26:24  * prbcquit (Read error: Connection reset by peer)
05:33:53  * prbcjoined
05:39:37  * BigBangUDRjoined
05:53:48  * prbcquit (Remote host closed the connection)
07:07:44  * Guest57960changed nick to X-warrior
07:07:47  * X-warriorquit (Changing host)
07:07:47  * X-warriorjoined
07:07:50  <X-warrior>Does anybody know a session system similar to expressjs/session that used tokens instead of cookies?
07:20:33  * nabdevjoined
08:00:01  * AKPWDjoined
08:14:45  * pizthewizjoined
08:19:52  * d4rklit3quit (Quit: My Mac Pro has gone to sleep. ZZZzzz…)
08:35:40  * pizthewizquit (Quit: 😴)
08:40:32  * stuf123joined
08:40:44  * stuf123part
08:41:25  <eaSy60>Hello X-warrior
08:41:32  <X-warrior>eaSy60, morning
08:42:01  <eaSy60>I generate a token each time a user logs in
08:42:19  <eaSy60>He needs to send it to the API in the headers with his userId
08:42:32  <eaSy60>I made a middleware for that
08:43:09  <eaSy60>The middleware `loadUser` checks the token and set req.currentUser
08:43:23  <eaSy60>or sends 404
08:43:31  <X-warrior>I guess it should be 401
08:43:32  <X-warrior>x)
08:47:34  <X-warrior>eaSy60, but yes, I got the main idea, but on that way, every request will do a database query to retrieve user x)
08:47:47  <eaSy60>yes exactly
08:47:53  <X-warrior>I did that as well, than I noticed I need something a little bit more complex
08:55:09  <eaSy60>I don't need anything more complex for the authentication
08:55:37  <eaSy60>But sure I made something strong for the authorization and params validation
09:07:45  <X-warrior>eaSy60, well, just imagine that you have a lot of requests and would like to use redis as some kind of cache mapping token -> user_id, so in application I could skip this current_user select since most of time I just need the user_id to work with x)
09:07:56  <X-warrior>anyway, I think I'm getting into it
09:08:08  <X-warrior>anyway, thanks for the help ;)
09:08:10  <eaSy60>Yes but it's not restful
09:33:11  * X-warriorquit (Quit: ty)
12:12:37  * dmarrquit (Ping timeout: 258 seconds)
12:12:42  * dmarrjoined
12:34:24  * nabdevquit (Ping timeout: 245 seconds)
12:53:12  * nabdevjoined
12:53:12  * nabdevquit (Changing host)
12:53:12  * nabdevjoined
12:54:19  * BigBangUDRquit (Quit: BigBangUDR)
13:00:37  * nabdevquit (Read error: Connection reset by peer)
13:21:32  * emanresu404quit (Ping timeout: 245 seconds)
13:28:43  * emanresu404joined
14:30:52  * prbcjoined
14:37:47  * emanresu404quit (Ping timeout: 245 seconds)
14:50:41  * prbcquit (Read error: Connection reset by peer)
14:52:29  * prbcjoined
15:11:53  * prbcquit (Ping timeout: 264 seconds)
15:20:55  * prbcjoined
15:21:54  * prbcquit (Remote host closed the connection)
15:25:04  * BigBangUDRjoined
15:34:09  * BigBangUDRquit (Quit: BigBangUDR)
15:43:19  * prbcjoined
16:03:56  * prbcquit (Remote host closed the connection)
16:52:32  * eaSy60quit
17:45:31  * pizthewizjoined
18:37:28  * thomasreggijoined
18:39:38  * d4rklit3joined
19:28:55  * prbcjoined
19:55:57  * gurke_joined
20:33:55  * gurke_quit (Quit: Textual IRC Client: www.textualapp.com)
20:57:48  * jeffmjack_joined
21:03:50  * blitheBoudicajoined
22:26:38  * cozbyquit (Quit: Leaving.)
22:36:45  * cozbyjoined
22:42:21  * prbcquit (Ping timeout: 260 seconds)
22:50:18  * prbcjoined
22:51:25  * thomasreggiquit (Remote host closed the connection)
23:35:23  * thomasreggijoined
23:56:14  * blitheBoudicaquit (Ping timeout: 258 seconds)
23:56:37  * prbcquit (Ping timeout: 258 seconds)
23:56:57  * prbcjoined