1
0
mirror of https://github.com/volatiletech/authboss.git synced 2024-11-24 08:42:17 +02:00
Commit Graph

57 Commits

Author SHA1 Message Date
Aaron L
931ccfba1f Add twofactor setup e-mail validation options 2018-11-01 22:49:25 -07:00
Aaron L
8213e87e83 Rewrite docs to 80 cols
- Fix #183
2018-09-15 15:39:26 -07:00
Aaron L
2eeaf342f9 Add control over confirm http method 2018-09-12 19:58:56 -07:00
Aaron L
79d1893bdc Add ability to override mail root
- Add config option for MailRoot
- Make confirm and recover use MailRoot if present, otherwise assemble
  URL like normal.
2018-09-12 19:49:48 -07:00
Aaron L
98147bc020 Fix several lint errors 2018-09-03 16:34:10 -07:00
Aaron L
735cbb1ec5 Add totp2fa module 2018-08-22 21:34:38 -07:00
Aaron L
b7cec028b9 Use io.ReadFull to read from crypto/rand
There have been bugs filed in other libraries where rand.Read()
simply returns all 0s, instead use io.ReadFull to ensure that we get
the amount of bytes we want.

- Use io.ReadFull(rand.Reader, ...) instead of rand.Read() for getting
  randomness from crypto/rand.
2018-07-17 10:10:07 -07:00
Aaron L
ae5a471cf2 Don't use magic numbers 2018-05-18 06:49:21 -07:00
Aaron L
852508259c Add split tokens for confirm and recover 2018-05-16 11:51:55 -07:00
Aaron L
bf1eb39403 Port FromName fix from master
Originally contributed by Max Howald <maxhowald@gmail.com>
2018-05-14 11:47:34 -07:00
Aaron L
ee4b2658d5 Finish TODOs 2018-03-09 13:11:08 -08:00
Aaron L
634892e29c Fix breakages from last commit 2018-03-07 16:41:58 -08:00
Aaron L
792f7381fd Change the form of Middleware functions
- Make this change to make it a bit more chi/alice friendly
  since this is typically the form of middlewares to be constructed
  and then turn into a "middleware" function/type.
2018-03-07 13:01:35 -08:00
Aaron L
0eff53792f Fully re-implement recover
- Add back the feature to log in after password recovery
- Add new storer functionality to mocks
- Add RecoveringServerStorer
- Add RecoverableUser
- Add RecoverStartValuer, RecoverMiddleValuer, RecoverEndValuer
- Change storers to differentiate between tokens (recover vs confirm)
- Change BCryptCost to be a generic module configuration (doesn't belong
  to register)
2018-03-05 17:47:11 -08:00
Aaron L
62dd36b71e Remove commented tests 2018-02-27 08:03:47 -08:00
Aaron L
38268f7a6b Finish unfinished middleware 2018-02-27 07:41:01 -08:00
Aaron L
982025bbc3 Finish implementing and testing confirm
- Rejig tests to remember to test the smtp mailer
2018-02-27 07:14:30 -08:00
Aaron L
ad5230a303 Bring back events
- Rename callbacks -> events
- Regenerate stringers.go with later version of stringer
2018-02-01 16:31:08 -08:00
Aaron L
de1c2ed081 Get tests working after latest refactors
- Change changelog format to use keepachangelog standard
- Refactor the config to be made of substructs to help organize all the
  pieces
- Add the new interfaces to the configuration
- Clean up module loading (no unnecessary reflection to create new value)
- Change User interface to have a Get/SetPID not E-mail/Username, this
  way we don't ever have to refer to one or the other, we just always
  assume pid. In the case of Confirm/Recover we'll have to make a GetEmail
  or there won't be a way for us to get the e-mail to send to.
- Delete the xsrf nonsense in the core
2018-02-01 15:42:48 -08:00
Aaron L
2b5c85ee16 Import path fixes 2017-07-30 19:42:05 -07:00
Aaron L
fa6ba517db More gigantic edits.
- Change response to be more central to Authboss. Make sure it has
  useful methods and works with the new rendering idioms.
- Change the load user methods to all work with context keys, and even
  be able to set context keys on the current request to avoid setting
  contexts everywhere in the code base.
2017-02-23 16:13:25 -08:00
Aaron L
f65d9f6bb6 Fix errors package
- Fix many compilation errors
2017-02-21 15:04:30 -08:00
Aaron L
0c3d6d26ca Remove gopkg.in 2016-12-19 22:47:12 -08:00
Ryan Lester
96c55ccaaa no DisableGoroutines (just check for -Maker); no ModuleNames; test fix 2016-05-09 13:20:10 -04:00
Ryan Lester
48f0e8a75a Merge remote-tracking branch 'upstream/master' 2016-05-09 12:14:18 -04:00
Aaron L
e76838cc1e Fix go vet errors 2016-05-08 12:37:02 -07:00
Ryan Lester
588c21260c final App-Engine-related fixes 2016-05-07 02:12:20 -04:00
Aaron L
b09e4831b6 Fix an issue where user is db fetched twice
- Fix #79
- Rename event EventGet to EventGetUser
- Remove double DB fetch
- Add new event callpoint: After(EventGetUser) for things that need to
  check that the user is ABLE to be gotten after it's fetched from the
  DB. That is before returning to the web app, ensure that the user is
  valid from a confirmation/lock etc point of view.
- Add test to make sure all the events are firing in CurrentUser()
2015-09-21 20:53:51 -07:00
Aaron L
905e9bfcb4 confirm: Context-Request separation ripple 2015-08-02 11:55:39 -07:00
Aaron
c98ef93e06 Fix modules after refactor. 2015-04-01 13:08:08 -07:00
Aaron
f12f10fa43 Stop reliance on global scope.
- This change was necessary because multi-tenancy sites could not use
  authboss properly.
2015-03-31 12:34:03 -07:00
Kris Runzer
5bdcddd9da Rename internal/render to internal/response 2015-03-28 09:08:05 -07:00
Kris Runzer
db1eb3a9a8 Add redir override. All redirects now occur through render.Redirect 2015-03-28 08:53:32 -07:00
Aaron
1c275a132a Make storage requirements more consistent.
- Fix #44
2015-03-27 09:35:54 -07:00
Aaron L
3d905f001f Go vet fixes. 2015-03-16 14:51:44 -07:00
Aaron L
99d0af8b72 Destroy a list of go lint errors. 2015-03-16 14:42:45 -07:00
Aaron
e14efb13b7 Make confirm redirect to a sane path. 2015-03-15 11:56:15 -07:00
Aaron
87e0ab9835 Delete useless readme files. 2015-03-15 11:24:38 -07:00
Aaron
f93fb38181 Change documentation a little bit, and fix one bug. 2015-03-15 08:06:08 -07:00
Aaron
dccabb0754 Rename HostName to RootURL 2015-03-12 19:20:28 -07:00
Kris Runzer
7ff35efe54 Split emails to have seperate HTML and Text layouts. 2015-03-03 11:23:49 -08:00
Kris Runzer
a7a67981ce Move create from Storer to RegisterStorer
- Fixed the qq tests
- Removed all module singletons
2015-03-01 20:00:19 -08:00
Kris Runzer
c8e2058440 Fix flash message clearing
- Fix token emailing bug with confirm (l2base64)
2015-02-26 22:01:53 -08:00
Aaron
b93e0e6eb1 Add callback from confirm to BeforeAuth
- Allow missing struct attributes to go unnoticed in Bind()
2015-02-26 12:15:33 -08:00
Aaron
8b1007f7dd Fix broken redirect tests. 2015-02-24 23:45:55 -08:00
Aaron
1075149bb8 Add router tests.
- Rename Endpoint to Location in ErrAndRedirect
2015-02-24 14:45:37 -08:00
Aaron
c723f46a3e Refactor storers into modules. 2015-02-24 11:04:27 -08:00
Aaron
73dcb5beb1 Add a few updates to documentation. 2015-02-22 22:27:45 -08:00
Aaron
001810bf7c Add PrimaryID to the system.
- Fix #17
2015-02-22 13:24:53 -08:00
Aaron
94f441f3d7 Fix confirm module. 2015-02-22 00:09:52 -08:00