Commit Graph

43 Commits

Author SHA1 Message Date
07d19e6b77
go: handle demoting admin to regular-user level
All checks were successful
continuous-integration/drone/push Build is passing
2023-09-04 20:27:14 +02:00
e10fdc5042
go: update last_login for users w/ finished setup
All checks were successful
continuous-integration/drone/push Build is passing
2023-09-04 20:02:21 +02:00
f4bd798821
fix(go): reject empty/same passwd on init change
All checks were successful
continuous-integration/drone/push Build is passing
2023-09-04 11:28:23 +02:00
6b45213649
go: add user onboarding, HIBP search functionality
All checks were successful
continuous-integration/drone/push Build is passing
* add user onboarding workflow
* fix user editing (no edits of passwords of regular users after
  onboarding)
* refresh HIBP breach cache in DB on app start-up
* display HIBP breach details
* fix request scheduling to prevent panics (this still needs some love..)
* fix middleware auth
* add TODOs
* update head.tmpl
* reword some error messages
2023-08-24 18:43:24 +02:00
247c95f753
go: save all breaches as cache, search by name
All checks were successful
continuous-integration/drone/push Build is passing
* also switch addedDate column to string temporarily, until saving
  yy-mm-dd as time is solved...
2023-08-24 03:59:50 +02:00
9fb9cc2735
go(hibp): add AllBreachesForAccount + amend tests
All checks were successful
continuous-integration/drone/push Build is passing
* also automatically use hibp api key with direnv and in CI
* check for rate-limit
* don't interpret rate-limit in tests as a failure
* report errors properly
2023-08-24 02:05:22 +02:00
f2025395b2
go: add basic hibp handling, requests scheduling
All checks were successful
continuous-integration/drone/push Build is passing
* change hibp schema's date field to string, as the date format would
  prevent direct unmarshaling. instead, marshal to string, convert later
* the scheduler is in place in order not to get throttled after going
  over API limit
* the scheduler detects when in testing mode and changes little bits of
  behaviour
* add tests for some basic requests
* run the requests scheduler as a background service during testing
2023-08-22 19:57:48 +02:00
7a877b01bb
go: implement import of local breach data
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-20 05:20:33 +02:00
f8364605e4
go: add handling of argon2 to the password module
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-19 04:28:00 +02:00
600ef9d445
go: add a way to display upcoming db migrations
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-13 16:57:19 +02:00
eff9b1e0eb
go(deps): use gopkg.in/yaml.v3
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-10 19:10:57 +02:00
d9c3fc1d68
go(localbreach): tweak code,test for multidoc yaml
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-08 23:20:09 +02:00
c3a565adf5
go(localbreach): add test+testdata
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-07 22:10:48 +02:00
cd2a7ed6de
localbreach: add hashPeppered field
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-07 22:06:18 +02:00
1c67191c09
feat: implement user deletion
All checks were successful
continuous-integration/drone/push Build is passing
2023-08-07 21:29:30 +02:00
85fe3d4c9d
go: replace deprecated 'ioutil' imports by 'os' 2023-07-19 21:29:22 +02:00
leo
416012f80f
go(user_test): add explicit FailNow()
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-04 11:38:56 +02:00
leo
5f8548958f
go: add usr updating [wip]
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-02 20:00:14 +02:00
leo
ae5c4f1dd4
go,tmpl: add usr details listing
All checks were successful
continuous-integration/drone/push Build is passing
* add tmpl
* add handler for route /manage/user/:id
* add convenience helper func
* handle not found/invalid uuid errors
2023-05-29 22:42:18 +02:00
leo
11de8de558
go: add local breach data schema
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-26 01:59:09 +02:00
leo
97ea29d043
add user listing
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-22 03:22:58 +02:00
leo
6ce05ea74d
feat: add initial admin user creation
All checks were successful
continuous-integration/drone/push Build is passing
have the app create the initial admin user:
* if the db has not yet been set up
* if there are not users
* if the config value for Init.CreateAdmin is True
* if the admin password is not empty

default username, email values can be seen in modules/user/const.go
2023-05-21 18:50:41 +02:00
leo
3a2f85f683
feat: add license headers (+spdx id)
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-20 20:15:57 +02:00
leo
852cc60a9e
go(funcmap): add sha384,sha512 funcs
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-14 22:53:25 +02:00
leo
e8ac4e39ce
modules/funcmap: add funcs to calculate SRI hashes
All checks were successful
continuous-integration/drone/push Build is passing
* correctly handle LiveMode resp. whether or not to set/read embeds
2023-05-12 00:11:23 +02:00
leo
adeb6f5720
go: create funcmap,bluemonday modules
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-11 18:16:15 +02:00
leo
1fb7479d8e
slogger: rename Logger to Slogger
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-11 17:06:20 +02:00
leo
122ea638c9
go: refactor template rendering
All checks were successful
continuous-integration/drone/push Build is passing
* create pkg 'modules/template'
* move template rendering code from 'handlers' to 'modules/template'
* update call sites
* walk the 'templates' dir to discover nested hierarchies
* solidify LiveMode handling (vs embedded assets)
* break out funcMap to it's own file
* general clean-up
2023-05-11 04:32:39 +02:00
leo
a879704535
go: partially rework how slogging works
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-09 17:35:00 +02:00
leo
eafc9c1e92
go,tmpl: conditionally show content to users
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-06 00:03:41 +02:00
leo
b1ab686493
go: add db module for preps/checks
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-05 22:52:59 +02:00
leo
0a5d4e7d30
go: use enttest in tests
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 23:21:47 +02:00
leo
0ac668d001
mod/usr: fix typo [skip ci]
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 22:43:51 +02:00
leo
4f2302143d
mod/user: rewrite some if statements as switches
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 22:42:08 +02:00
leo
a2c17693c6
go: save,verify a bcrypt hash of the passwd
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 06:30:12 +02:00
leo
5a3ce50bb2
mod/user: don't print out the raw usr object
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 06:09:44 +02:00
leo
faefe3b577
mod/user: add check for when usr is not found
All checks were successful
continuous-integration/drone/push Build is passing
2023-05-03 06:08:28 +02:00
leo
593454d616
go: add user email handling + improve sessions
All checks were successful
continuous-integration/drone/push Build is passing
* add Email field to User entity (+codegen)
* switch to Echo contrib sessions backed by Gorilla sessions
* use SessionCookieSecret value from the config
* stage mod,sum changes
* add clearer signup/signin redirect logic
* render error pages on 500/404s and only fall back to returning raw
  errors when the error is some unexpected kind
* add username/email "exists" funcs+tests - handle "not found" and "not
  unique" errors, return errors otherwise
2023-05-01 22:48:11 +02:00
leo
edf720bcb9
go: create proper (non-string) ctx key in user pkg
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-19 23:44:49 +02:00
leo
c6378d7dd3
pass logger ctx under key 'l'
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-19 05:18:01 +02:00
leo
c6896bdee2
modules/password: simplify return
All checks were successful
continuous-integration/drone/push Build is passing
2023-04-19 03:51:42 +02:00
leo
8cc43bba13
go: switch to a custom slog-based logging solution
All checks were successful
continuous-integration/drone/push Build is passing
* make all packages use the logger
* add a couple of convenience methods on the logger that enable
  formatting using fmt syntax
2023-04-19 02:12:27 +02:00
leo
f129606b8f
add bulk changes
All checks were successful
continuous-integration/drone/push Build is passing
* add handlers for signin,singup,logout...
* introduce ent ORM and add user schema
* add live mode, devel mode to selectively turn on features via
  config/flags
* add templates, handle embedding moar smarter:
  * live mode uses live folder structure, else embedded templates are
    used
* start using tailwindcss to style stuff
* add development goodies for hot-reloading (browser-sync - bs.js)
* pimp-up config.dhall with actual custom config Type (enables remote
  schema and local values only as needed)
* add justfile (alternative to makefile for process automation)
2023-04-13 00:07:08 +02:00