Commit Graph
194 Commits
Author SHA1 Message Date
lukaszraczylo cc6d6693e0 fixup! fixup! fixup! fixup! Weekend fun with further optimisations. v0.7.0-rc.3-beta1 2025-09-14 23:47:16 +01:00
lukaszraczylo f411273fa2 fixup! fixup! fixup! Weekend fun with further optimisations. 2025-09-14 18:28:32 +01:00
lukaszraczylo 9af8939f72 fixup! fixup! Weekend fun with further optimisations. v0.7.0-rc.3 2025-09-14 01:54:06 +01:00
lukaszraczylo 0d88612d8c fixup! Weekend fun with further optimisations. 2025-09-14 01:40:03 +01:00
lukaszraczylo 7457a901a9 Weekend fun with further optimisations. v0.7.0-rc.2 2025-09-13 23:42:02 +01:00
lukaszraczylo a31fd64112 fixup! fixup! Splitting code into multiple files with reasonable testing coverage. 2025-09-09 09:20:10 +01:00
lukaszraczylo c04f949656 fixup! Splitting code into multiple files with reasonable testing coverage. v0.7.0-rc.1 2025-09-07 13:01:08 +01:00
lukaszraczylo 4371f9fffd Splitting code into multiple files with reasonable testing coverage.
```
ok      github.com/lukaszraczylo/traefikoidc    117.017s        coverage: 72.6% of statements
ok      github.com/lukaszraczylo/traefikoidc/auth       0.505s  coverage: 87.1% of statements
ok      github.com/lukaszraczylo/traefikoidc/circuit_breaker    0.283s  coverage: 99.0% of statements
        github.com/lukaszraczylo/traefikoidc/config             coverage: 0.0% of statements
ok      github.com/lukaszraczylo/traefikoidc/handlers   0.349s  coverage: 98.2% of statements
ok      github.com/lukaszraczylo/traefikoidc/internal/providers (cached)        coverage: 94.3% of statements
ok      github.com/lukaszraczylo/traefikoidc/middleware 0.808s  coverage: 78.0% of statements
ok      github.com/lukaszraczylo/traefikoidc/recovery   0.653s  coverage: 100.0% of statements
ok      github.com/lukaszraczylo/traefikoidc/session/chunking   (cached)        coverage: 87.8% of statements
ok      github.com/lukaszraczylo/traefikoidc/session/core       (cached)        coverage: 85.6% of statements
ok      github.com/lukaszraczylo/traefikoidc/session/crypto     (cached)        coverage: 81.8% of statements
ok      github.com/lukaszraczylo/traefikoidc/session/storage    (cached)        coverage: 93.5% of statements
ok      github.com/lukaszraczylo/traefikoidc/session/validators (cached)        coverage: 98.8% of statements
````
2025-09-07 12:57:18 +01:00
lukaszraczylo c9a23dc6c0 Weekend fun with memory leaks v0.7.0-beta17 2025-09-07 03:02:34 +01:00
lukaszraczylo e17b820368 fixup! Clear race conditions 2025-09-06 13:17:54 +01:00
lukaszraczylo bf6ab31c50 Clear race conditions 2025-09-06 10:38:32 +01:00
lukaszraczylo a34488f533 fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Further pursue of perfection. 2025-09-06 03:23:03 +01:00
lukaszraczylo 05c316002d fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Further pursue of perfection. v0.7.0-beta16 2025-09-06 03:12:59 +01:00
lukaszraczylo f96940921b fixup! fixup! fixup! fixup! fixup! fixup! fixup! Further pursue of perfection. v0.7.0-beta15 2025-09-06 01:02:04 +01:00
lukaszraczylo a1c0bce4be fixup! fixup! fixup! fixup! fixup! fixup! Further pursue of perfection. v0.7.0-beta14 2025-09-06 00:36:50 +01:00
lukaszraczylo eab8e04573 fixup! fixup! fixup! fixup! fixup! Further pursue of perfection. v0.7.0-beta12 2025-09-06 00:24:46 +01:00
lukaszraczylo b182951f22 fixup! fixup! fixup! fixup! Further pursue of perfection. 2025-09-05 16:17:02 +01:00
lukaszraczylo e267cb3a6f fixup! fixup! fixup! Further pursue of perfection. 2025-09-05 13:57:54 +01:00
lukaszraczylo 2c902eaafb fixup! fixup! Further pursue of perfection. 2025-09-05 00:22:13 +01:00
lukaszraczylo f291dcca26 fixup! Further pursue of perfection. v0.7.0-beta11 2025-09-04 22:43:39 +01:00
lukaszraczylo 29ec26cbaa Further pursue of perfection. v0.7.0-beta10 2025-09-03 23:26:06 +01:00
lukaszraczylo dc16b4fc94 Memory leaks hunting, part 1337. v0.7.0-beta9 2025-09-03 13:20:39 +01:00
lukaszraczylo 7db2f8d66c fixup! Metadata cache leak fix + profiling v0.7.0-beta8 2025-09-02 17:03:50 +01:00
lukaszraczylo 024e349aa9 Metadata cache leak fix + profiling 2025-09-02 16:42:22 +01:00
lukaszraczylo 873105108e fixup! CSRF and Cookie Domain fixes 2025-08-29 11:07:02 +01:00
lukaszraczylo 5241cfe792 CSRF and Cookie Domain fixes v0.7.0-beta6 v0.7.0-beta7 2025-08-28 10:45:19 +01:00
lukaszraczylo e2e2be53c1 Memory leak fixes and optimisations. v0.7.0-beta5 2025-08-28 09:59:47 +01:00
lukaszraczylo c878784f1e Next set of enhancements together with memory usage improvements. v0.7.0-beta3 2025-08-27 10:35:46 +01:00
lukaszraczylo 1fd762848a Issue #53: Fix CSRF token handling in reverse proxy
1. ✅ HTTPS Detection Fixed (session.go:723)
- Now uses X-Forwarded-Proto header instead of r.URL.Scheme
- Properly detects HTTPS in reverse proxy environments
2. ✅ SameSite Cookie Attribute Fixed
- Removed automatic SameSiteStrictMode for HTTPS (would break OAuth)
- Keeps SameSiteLaxMode to allow OAuth callbacks from external domains
- Only uses Strict for AJAX requests which don't involve OAuth redirects
3. ✅ Cookie Domain Handling Fixed
- Now respects X-Forwarded-Host header for cookie domain
- Ensures cookies are set for the public domain, not internal proxy domain
4. ✅ EnhanceSessionSecurity Properly Integrated
- Function is now actually called during session save
- Applies security enhancements without breaking OAuth flow

Why Issue #53 Failed Before:

1. Cookies were not marked Secure in HTTPS environments (browser wouldn't send them back)
2. If they had been Secure with SameSite=Strict, Azure callbacks would still fail
3. Cookie domain might have been wrong (internal vs public domain)

Why It Works Now:

1. Cookies are properly marked Secure for HTTPS
2. Uses SameSite=Lax to allow OAuth provider callbacks
3. Cookie domain uses public domain from X-Forwarded-Host
4. CSRF token persists through the entire OAuth flow
2025-08-14 12:10:51 +01:00
lukaszraczylo a4b2bfd70f fixup! fixup! fixup! fixup! fixup! Cleanup tests. v0.7.0-beta1 2025-07-24 10:29:08 +01:00
lukaszraczylo 00ed2ea61b fixup! fixup! fixup! fixup! Cleanup tests. 2025-07-24 10:05:50 +01:00
lukaszraczylo 2c2f92cd49 fixup! fixup! fixup! Cleanup tests. 2025-07-24 09:22:49 +01:00
lukaszraczylo 5fc719b162 fixup! fixup! Cleanup tests. 2025-07-24 09:17:28 +01:00
lukaszraczylo 242641c587 fixup! Cleanup tests. 2025-07-23 18:07:48 +01:00
lukaszraczylo f6b3f9ecab Cleanup tests. 2025-07-23 17:56:52 +01:00
lukaszraczylo af22256c96 ... 2025-07-23 17:56:33 +01:00
lukaszraczylo b7b0c60f03 fixup! fixup! fixup! fixup! Simplify all the things. 2025-07-22 12:53:19 +01:00
lukaszraczylo ce9614bb64 fixup! fixup! fixup! Simplify all the things. 2025-07-22 10:47:28 +01:00
ArulandGitHub 784b161732 Fix for cookie length (#58)
* Enhance session management by adding support for chunked id token in main session

* Add test for large ID token chunking in session management
v0.7.0-beta2 v0.7.0-beta4
2025-07-22 09:30:04 +01:00
lukaszraczylo 46745f5b54 fixup! fixup! Simplify all the things. v0.6.2-beta10 2025-06-24 23:55:21 +01:00
lukaszraczylo a54ae71279 fixup! Simplify all the things. 2025-06-24 22:30:21 +01:00
lukaszraczylo ae2a2877e9 Simplify all the things. 2025-06-24 19:54:05 +01:00
lukaszraczylo c2a81bc2df Additional micro fixes and cleanups. 2025-06-24 18:48:02 +01:00
lukaszraczylo dbe3455f49 Abstract the provider logic into a separate package. 2025-06-24 17:56:19 +01:00
lukaszraczylo 0dfc252c95 fixup! fixup! Bugfix #51: Ensures that user provided scopes overrides work. v0.6.2-beta9 2025-06-21 22:50:32 +01:00
lukaszraczylo 71574090bf fixup! Bugfix #51: Ensures that user provided scopes overrides work. 2025-06-21 22:39:45 +01:00
lukaszraczylo de91edb514 Bugfix #51: Ensures that user provided scopes overrides work. v0.6.2-beta8 2025-06-20 23:58:42 +01:00
lukaszraczylo 667b4213fe Well.. that escalated quickly.
Completely forgot that Traefik uses outdated Yaegi and requires compatibility with 1.20 ( pre-generic Go code ).
v0.6.2-beta7
2025-06-20 19:23:50 +01:00
lukaszraczylo 70443f0855 Add ability to overwrite the default scopes in the settings file v0.6.2-beta6 2025-06-20 11:31:29 +01:00
lukaszraczylo 7a443c626c Fix claims issue. 2025-06-20 09:47:22 +01:00