• Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
v3.5.2 Latest
Buy Hosting

NodeBB ACP-access broken

Scheduled Pinned Locked Moved Bug Reports
setupadmin
15 Posts 3 Posters 5.4k Views
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    wrote on last edited by frissdiegurke
    #6

    I've disabled the cache for this (request-header Cache-Control:no-cache) but without that the same result: 200.

    General

    Remote Address:[::1]:4567
    Request URL:http://localhost:4567/login?local=1
    Request Method:POST
    Status Code:200 OK
    

    Response Headers

    Connection:keep-alive
    Content-Length:6
    Content-Type:text/html; charset=utf-8
    Date:Sat, 18 Jul 2015 15:13:14 GMT
    ETag:W/"6-EfazKFv3GoeBHD2tzLexZg"
    set-cookie:express.sid=s%3AKZKFhtm5od-ur_JBgNkN1mZk-_MgogOF.r%2BamgtRRL1d%2Bun5NbhOxIuBW1W%2FJx7WAv9xp01UorXo; Path=/; Expires=Sat, 01 Aug 2015 15:13:14 GMT; HttpOnly
    Vary:Accept-Encoding
    X-Frame-Options:SAMEORIGIN
    X-Powered-By:NodeBB
    

    Request Headers

    Accept:*/*
    Accept-Encoding:gzip, deflate
    Accept-Language:en-US,en;q=0.8,de;q=0.6
    Cache-Control:no-cache
    Connection:keep-alive
    Content-Length:113
    Content-Type:application/x-www-form-urlencoded; charset=UTF-8
    Cookie:org.cups.sid=6592779d4f2a1725f4c410957b3ffef2; connect.sid=s%3AR0QEUPdPVSiS5tazLC8bkdhtLmjyYEnp.Q5Eucy7fsCVN22WViBWuZaWgmOzhFKrayNvnkdYuleY; express.sid=s%3AKZKFhtm5od-ur_JBgNkN1mZk-_MgogOF.r%2BamgtRRL1d%2Bun5NbhOxIuBW1W%2FJx7WAv9xp01UorXo
    Host:localhost:4567
    Origin:http://localhost:4567
    Pragma:no-cache
    Referer:http://localhost:4567/login?local=1
    User-Agent:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.134 Safari/537.36
    x-csrf-token:CgqEiLEc-Cq3OXMXAyRURBWlCuo0Ep_tvsEU
    X-Requested-With:XMLHttpRequest
    

    Query String Parameters

    local:1
    

    Form Data

    username:frissdiegurke
    password:***
    remember:on
    returnTo:http://localhost:4567/login?local=1
    

    I've also tried with other returnTo value (http://localhost:4567/tags) but same result 200 and redirect to /login?local=1

    EDIT: After cleaning cookies (more specific express.sid) I can login again but as soon I try to access /admin it's the same all over again.

    1 Reply Last reply
    0
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    wrote on last edited by
    #7

    The request to /admin itself when logged in (and avatar is showed, etc.) results in a 302 as it seems:

    General

    Remote Address:[::1]:4567
    Request URL:http://localhost:4567/admin
    Request Method:GET
    Status Code:302 Moved Temporarily
    

    Response Headers

    Connection:keep-alive
    Content-Length:84
    Content-Type:text/html; charset=utf-8
    Date:Sat, 18 Jul 2015 15:41:47 GMT
    Location:/login?local=1
    set-cookie:express.sid=s%3ASnR2fDlqTEBDunA6DAyurgERQy9LvZwj.jmjluB9kDCE%2BSEhCtxTpzgcakpjJa%2BKOpuFYYSgtmIo; Path=/; Expires=Sat, 01 Aug 2015 15:41:47 GMT; HttpOnly
    Vary:Accept, Accept-Encoding
    X-Frame-Options:SAMEORIGIN
    X-Powered-By:NodeBB
    

    Request Headers

    Accept:text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
    Accept-Encoding:gzip, deflate, sdch
    Accept-Language:en-US,en;q=0.8,de;q=0.6
    Cache-Control:no-cache
    Connection:keep-alive
    Cookie:express.sid=s%3ABq2PBi6iT5jaRQ6Qg3ojLy9PyWB0dRe6.VgpaSnS%2B%2BvdTxoJkxieZgw4ZpOWzUxJZOOH%2BWygCNqw; express.sid=s%3AYryeHEojKdlk3cc9SBmIegkusB9GeJ70.wJ5jXbD5oqvrygsWvUKMbq8mVJGIXrprt%2F%2F3OAH0jn0
    Host:localhost:4567
    Pragma:no-cache
    Referer:http://localhost:4567/unread
    User-Agent:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.134 Safari/537.36
    

    Maybe the two different express.sid request-cookies have sth to do with this o_O

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #8

    Can you try switching the session store to redis and see if that helps?

    1 Reply Last reply
    0
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    wrote on last edited by
    #9

    I've used redis in first place, just switched to mongodb for debugging purpose since I'm not familiar with redis commands.
    So everything happens using redis the same way.

    1 Reply Last reply
    0
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #10

    Highly peculiar... and does this also happen on, say... a cloud install?

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #11

    @frissdiegurke Does this happen with node 0.10.x?

    frissdiegurkeF 1 Reply Last reply
    0
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    replied to <baris> on last edited by
    #12

    @baris said:

    @frissdiegurke Does this happen with node 0.10.x?

    Since there is no way to install node 0.10.x (neither iojs, wanted to try this 😄 ) without purging my current version I'm not willing to do this.

    I've just tried to remove all global installed node_modules (rm -rf /usr/lib/node_modules), clean npm cache and reinstall npm and my global modules.
    But it still didn't fix the problem (fixed some non-related errors though).

    I'll try on my desktop-pc (also bleeding-edge arch-linux) later this day to see if it works there.

    1 Reply Last reply
    0
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #13

    You could try installing nvm, which would allow you to "install" Node from within your home directory...

    Then you can switch between 0.10, 0.11, 0.12, and even iojs, with a single nvm use command.

    Of course, you do have to npm rebuild each time, but that's not so bad.

    frissdiegurkeF 1 Reply Last reply
    0
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    replied to julian on last edited by
    #14

    @julian well, that's affordable 😄 didn't know nvm thanks!

    Using nodejs v0.10.40 (npm 1.4.28) and npm rb within NodeBB root, flushing db and calling ./nodebb setup again... The issue still persists o_O

    I've also tried the v0.6.x branch (using nodejs 0.12.x) where the same issue occurs, so it's definitely no fault within the NodeBB core (unless caused by lately bugfixes within that branch too)...

    As I said I'll test on desktop-pc later on. Maybe I'll also try around with docker some time (never used it yet, definitely need to xD ).

    1 Reply Last reply
    0
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #15

    Eh, try LXC. I recommend it over Docker 😄

    1 Reply Last reply
    0

Copyright © 2023 NodeBB | Contributors
  • Login

  • Don't have an account? Register

  • Login or register to search.
Powered by NodeBB Contributors
  • First post
    Last post
0
  • Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development