forgejo/modules
Gusted 51988ef52b
[GITEA] rework long-term authentication
- The current architecture is inherently insecure, because you can
construct the 'secret' cookie value with values that are available in
the database. Thus provides zero protection when a database is
dumped/leaked.
- This patch implements a new architecture that's inspired from: [Paragonie Initiative](https://paragonie.com/blog/2015/04/secure-authentication-php-with-long-term-persistence#secure-remember-me-cookies).
- Integration testing is added to ensure the new mechanism works.
- Removes a setting, because it's not used anymore.

(cherry-pick from eff097448b)

Conflicts:

	modules/context/context_cookie.go
	trivial context conflicts

	routers/web/web.go
	ctx.GetSiteCookie(setting.CookieRememberName) moved from services/auth/middleware.go
2023-10-05 08:50:54 +02:00
..
actions [CI] Search .forgejo/workflows first 2023-07-16 23:21:44 +02:00
activitypub Add Chef package registry (#22554) 2023-02-06 09:49:21 +08:00
analyze
assetfs Skip unuseful error message in dev mode when watching local filesystem (#25919) (#25927) 2023-07-24 07:58:56 +02:00
auth [SECURITY] default to pbkdf2 with 320,000 iterations 2023-07-16 23:44:22 +02:00
avatar Improve avatar uploading / resizing / compressing, remove Fomantic card module (#24653) 2023-05-13 20:59:11 +02:00
base Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
cache Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
charset Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
container
context [GITEA] rework long-term authentication 2023-10-05 08:50:54 +02:00
csv Refactor locale number (#24134) 2023-04-17 11:37:23 +08:00
doctor fix orphan check for deleted branch (#27310) (#27320) 2023-10-03 14:48:40 +02:00
emoji
eventsource Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
generate
git Fix git 2.11 error when checking IsEmpty (#27393) (#27396) 2023-10-03 14:48:40 +02:00
gitgraph Add context cache as a request level cache (#22294) 2023-02-15 21:37:34 +08:00
graceful Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
hcaptcha
highlight test_env: hardcode major go version in use (#23464) 2023-03-14 16:09:01 -04:00
hostmatcher
html Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
httpcache [BRANDING] add X-Forgejo-* headers 2023-07-17 00:25:55 +02:00
httplib Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
indexer Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
issue/template Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
json Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
label Make label templates have consistent behavior and priority (#23749) 2023-04-10 16:44:02 +08:00
lfs Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
log Use stderr as fallback if the log file can't be opened (#26074) (#26083) 2023-07-26 13:49:15 +02:00
markup [GITEA] Use restricted sanitizer for repository description 2023-09-13 17:17:37 +02:00
mcaptcha
metrics Use a separate admin page to show global stats, remove actions stat (#25062) 2023-06-03 22:03:41 +08:00
migration Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
mirror Improve queue and logger context (#24924) 2023-05-26 07:31:55 +00:00
nosql Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
notification Load reviewer before sending notification (#27063) (#27064) 2023-09-20 12:50:46 +02:00
options Use a general approach to access custom/static/builtin assets (#24022) 2023-04-12 18:16:45 +08:00
packages Prevent newline errors with Debian packages (#26332) (#26342) 2023-08-21 07:22:16 +02:00
paginator Use more specific test methods (#24265) 2023-04-22 17:56:27 -04:00
pprof
private [CLI] implement forgejo-cli actions register 2023-07-16 23:21:45 +02:00
process Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
proxy Use proxy for pull mirror (#22771) 2023-02-11 08:39:50 +08:00
proxyprotocol
public Use standard HTTP library to serve files (#24693) 2023-05-13 16:04:57 +02:00
queue Calculate MAX_WORKERS default value by CPU number (#26177) (#26183) 2023-07-30 07:46:18 +02:00
recaptcha
references
regexplru
repository Fix context cache bug & enable context cache for dashabord commits' authors(#26991) (#27017) 2023-09-20 12:50:46 +02:00
secret Improve decryption failure message (#24573) 2023-05-07 19:29:43 +08:00
session Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
setting [GITEA] rework long-term authentication 2023-10-05 08:50:54 +02:00
sitemap
ssh Fix admin queue page title and fix CI failures (#26409) (#26421) 2023-08-21 07:22:18 +02:00
storage Use correct minio error (#26634) (#26639) 2023-09-08 08:07:19 +02:00
structs Fix PushEvent NullPointerException jenkinsci/github-plugin (#27203) (#27249) 2023-10-03 14:48:40 +02:00
svg Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
sync
system
templates Fix context cache bug & enable context cache for dashabord commits' authors(#26991) (#27017) 2023-09-20 12:50:46 +02:00
test [TESTS] MockVariable temporarily replaces a global value 2023-08-21 07:22:17 +02:00
testlogger Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
timeutil Fix incorrect webhook time and use relative-time to display it (#24477) 2023-05-03 19:53:43 -04:00
translation Replace interface{} with any (#25686) (#25687) 2023-07-04 23:41:32 -04:00
turnstile
typesniffer Detect ogg mime-type as audio or video (#26494) (#26505) 2023-08-21 07:26:43 +02:00
updatechecker [PRIVACY] Add a DNS method to fetch new updates 2023-07-17 00:24:23 +02:00
upload
uri
user
util [GITEA] rework long-term authentication 2023-10-05 08:50:54 +02:00
validation check blocklist for emails when adding them to account (#26812) (#26831) 2023-09-08 08:09:18 +02:00
web Fix incorrect router logger (#26137) (#26143) 2023-07-26 13:49:15 +02:00
webhook [BRANDING] define the forgejo webhook type 2023-08-21 07:22:16 +02:00