SolidOS / mashlib

Solid-compatible data mashup library and Data Browser
https://solidos.github.io/mashlib/dist/browse.html
MIT License
71 stars 21 forks source link

Authentication code not up to date, resulting in broken login #155

Closed RubenVerborgh closed 2 years ago

RubenVerborgh commented 2 years ago

Steps to reproduce:

Result:

Uncaught (in promise) Error: Token endpoint returned error [server_error]: oops! something went wrong
    r OidcProviderError.js:6
    l index.es.js:110
    c index.es.js:159

And upon refresh:

XHRPOSThttps://drive.verborgh.org/.oidc/token
[[HTTP/2 400 Bad Request 253ms]]()

Uncaught (in promise) Error: Token endpoint returned error [invalid_grant]: grant request is invalid
    r https://drive.verborgh.org/mashlib.min.js:100
    l https://drive.verborgh.org/mashlib.min.js:52
    c https://drive.verborgh.org/mashlib.min.js:52
    p https://drive.verborgh.org/mashlib.min.js:52
    handle https://drive.verborgh.org/mashlib.min.js:127
    handle https://drive.verborgh.org/mashlib.min.js:127
    handleIncomingRedirect https://drive.verborgh.org/mashlib.min.js:127
    handleIncomingRedirect https://drive.verborgh.org/mashlib.min.js:100
    d https://drive.verborgh.org/mashlib.min.js:127
    s https://drive.verborgh.org/mashlib.min.js:127
    s https://drive.verborgh.org/mashlib.min.js:127
    o https://drive.verborgh.org/mashlib.min.js:127
    o https://drive.verborgh.org/mashlib.min.js:127
    checkUser https://drive.verborgh.org/mashlib.min.js:127
    runDataBrowser https://drive.verborgh.org/mashlib.min.js:193
    <anonymous> https://drive.verborgh.org/?code=JFhhsqGkf5qZswIwLHuvIQnx2B1AgKeUduf5WPcMQEG&state=3f59f44b0d53472f9432dc74baccc234:2
    EventListener.handleEvent* https://drive.verborgh.org/?code=JFhhsqGkf5qZswIwLHuvIQnx2B1AgKeUduf5WPcMQEG&state=3f59f44b0d53472f9432dc74baccc234:1

CSS is using the latest spec; Mashlib not yet.

bourgeoa commented 2 years ago

I think I add the same problem It was a clock problem with WSL2 https://gitter.im/solid/community-server?at=620a8f801fe6ba5a9725fe95

I'm running locally a https:localhost:3000 monorepo solidcommunity-server-recipes with mashlib v1.7.22 I had to synchronize the clock by restarting WSL2 https://snippets.khromov.se/how-to-restart-wsl2-windows-subsystem-linux-on-windows-10/

bourgeoa commented 2 years ago

I can also connect to your pod from mashlb 1.7.22 webapp image

RubenVerborgh commented 2 years ago

Thanks @bourgeoa, it was indeed user error.