Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Brian Gulotta
    @bgulotta
    instead of 500
    Aaron Heesakkers
    @aars
    That’s awesome! Will check it out after my coffee and stuff.
    Aaron Heesakkers
    @aars
    Mmm.. any good reason why getGravatarUrl is part of sails-auth? Seems mighty unrelated.
    Brian Gulotta
    @bgulotta
    not sure probably just to give a consistent way to show a users image within an application
    just updated that error code to return 403
    Aaron Heesakkers
    @aars
    Great. Thanks. Your PR was the last piece of the puzzle for me! Thanks for that.
    Brian Gulotta
    @bgulotta
    np. i'm planning on using both of these libraries in an api i'm working on as well
    want to make sure they are solid
    reproduce any issues with unit tests and then fix them
    Aaron Heesakkers
    @aars
    I’ll try to contribute, but my main goal is actually building this backend :) I’m forked sails-auth and are modifying it, since I though it was odd to override large parts of the AuthController for example. I’m not using a frontend on sails, so I have no use for redirects for example.
    And I also need to generate and return a bearer token after successfull local auth. That kind of stuff. As soon as I have a good overview of what I’m doing and the codebase I’m working in I’ll try to set it up as modular as possible.
    Brian Gulotta
    @bgulotta
    cool
    yeah i'm not using the sails for a front-end either
    Aaron Heesakkers
    @aars
    I have a sneaking suspicion that the passport protocol extensions in api/services/protocols/ don’t do anything/are useless. Since sails-auth requires them from it’s own subdir, there is nobody/nocode that requires the ‘extensions’ that are dropped in your project dir.
    I think it might be better to have a generate script that places a lot of these requirements in your project dir, most obvious example would be the AuthController. This would also encourage people to modify it to their own needs in a better way.. since now you either have to override some pretty specific flow (the redirects, the use of req.flash) in your subclass, or dive into your node_modules breaking easy dependencies.
    Aaron Heesakkers
    @aars
    Here are my current changes, by far useable for anybody else, got my own BearerToken model stuck in there (protocols/local.js). Will find a way to clean this up soon. https://github.com/aars/sails-auth/commits/master
    AuthController is probably a better place for creating that BearerToken.
    Or maybe some magic within passportjs? Somehow generate a token, store it in a common/good place and add it to the found user, but that last part is again custom code.
    Aaron Heesakkers
    @aars
    Gurrr… passport is trying to authenticate whenever I post a to-be-created user to my /users endpoints.. Hahaha.. ugh...
    I’m done with code for today. Time to break open this iMac and install some SSD sweetness. Cheers all! Thanks.
    Brian Gulotta
    @bgulotta
    SSD is goooooooooo
    d
    Aaron Heesakkers
    @aars
    Yeah, especially when running two node projects that both watch soo freaking many files :)
    Brian Gulotta
    @bgulotta
    using nodemon?
    Aaron Heesakkers
    @aars
    Yeah, at least one. There might be some grunt watching task as well.
    Poor machines doesn't handle it well.
    Aaron Heesakkers
    @aars
    That was one hell of an exercise! :D But it's in!
    Brian Gulotta
    @bgulotta
    everything nice and snappy now?
    Aaron Heesakkers
    @aars
    Still installing.
    Aaron Heesakkers
    @aars
    Because you really wanted to know: Yeah. Nice and snappy. I had never done any node work on a non-ssd, and I hope no-one ever should :)
    Travis Webb
    @tjwebb
    I've got two ssds in raid 0 in my laptop. I basically have 500gb of ram :)
    Aaron Heesakkers
    @aars
    Nice. No need for a .nodemonignore file then :)
    Aaron Heesakkers
    @aars
    @tjwebb Any thoughts on seperating the backend- (api, auth, models, etc) and frontend-stuff (redirects/tryAgain() method in AuthController mostly) of sails-auth? Also, any thoughts on what I said march 27? :point_up: March 27 2015 1:44 PM
    It seems to me that sails-auth (and sails-permissions in extension) are really the best packages out there. Would be great if they became a go-to package for auth. Are they? (I didn’t find them easily, found generate-auth first for example)
    Travis Webb
    @tjwebb
    @aars sails-(auth|permissions) are now in the official sails.js docs, in the policies section. I aim to get them in more places; currently they are the de facto official packages, since we at balderdash are recommending them to people who ask
    They are relatively new (1.0 release is only a month or so old) so full traction may take a little time
    Aaron Heesakkers
    @aars
    @ghaiklor I invited you to this room to hopefully discuss some improvements on sails-auth. (@tjwebb). I’ve got some “free time” the coming weeks and would love to contribute. What I would like to see/do:
    • decouple frontend-related stuff. (redirects, flash errors, etc)
    • Use generators/templates to prevent the need to edit node_modules (or override large pieces of code)
    • A better/clearer passportjs implementation?
    • jwt (or other token) authentication/generation.
    • do not break sails-permissions when doing this :)
    Eugene Obrezkov
    @ghaiklor
    Hi ) Yeah, no problem. Feel free to ask questions about passport. I'm going to implement more strategies with token, so I cant participate for now )
    And of course I cant forgot my yeoman generator )
    Aaron Heesakkers
    @aars
    Great! I’ll play around with your generator soon and see what I can pick up from it. Looks good.
    Aksimaya
    @Aksimaya
    Hey guys.. what is the difference between sails-auth (by tjwebb) & sails-generate-auth (by kasperisager) ? which one should i install better? i see that sails-generate-auth seems more complete because it has /views/auth/*.ejs for frontend. any idea @tjwebb ?
    Aaron Heesakkers
    @aars
    Those views are very simple and by the looks of it only used for demonstration purposes. But, it is a good question why sails-auth doesn’t have them, since it does redirect to in the AuthController, suggesting there is a frontend dependency.
    You could probably drop in these views as-is.
    Aksimaya
    @Aksimaya
    @aars tx.. will try to drop it. I just a little bit confused which one i should follow for the future version :D
    @aars you will code the jwt ? cool.. cant wait to use it :) so that i can test the permission with postman, no need to build the frontend first. Btw, i just using sails-auth, so sorry if to much comments / questions.