- Notifications
You must be signed in to change notification settings - Fork1k
Commit2d32123
committed
feat(oauth2): add RFC 8707 resource indicators and audience validation
Implements RFC 8707 Resource Indicators for OAuth2 provider to enable properaudience validation and token binding for multi-tenant scenarios.Key changes:- Add resource parameter support to authorization and token endpoints- Implement server-side audience validation for opaque tokens- Add database fields: ResourceUri (codes) and Audience (tokens)- Add comprehensive resource parameter validation logic- Add cross-resource audience validation in API middleware- Add extensive test coverage for RFC 8707 scenarios- Enhance PKCE implementation with timing attack protectionThis enables OAuth2 clients to specify target resource servers and preventstoken abuse across different Coder deployments through proper audience binding.Change-Id: I3924cb2139e837e3ac0b0bd40a5aeb59637ebc1bSigned-off-by: Thomas Kosiewski <tk@coder.com>1 parente6243ce commit2d32123
File tree
15 files changed
+1177
-7
lines changed- coderd
- database
- dbauthz
- dbmem
- dbmetrics
- dbmock
- queries
- httpmw
- identityprovider
15 files changed
+1177
-7
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
89 | 89 |
| |
90 | 90 |
| |
91 | 91 |
| |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
92 | 96 |
| |
93 | 97 |
| |
94 | 98 |
| |
| |||
125 | 129 |
| |
126 | 130 |
| |
127 | 131 |
| |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
128 | 155 |
| |
129 | 156 |
| |
130 | 157 |
| |
| |||
209 | 236 |
| |
210 | 237 |
| |
211 | 238 |
| |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
212 | 245 |
| |
213 | 246 |
| |
214 | 247 |
| |
| |||
265 | 298 |
| |
266 | 299 |
| |
267 | 300 |
| |
| 301 | + | |
| 302 | + | |
| 303 | + |
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
781 | 781 |
| |
782 | 782 |
| |
783 | 783 |
| |
| 784 | + | |
784 | 785 |
| |
785 | 786 |
| |
786 | 787 |
| |
| |||
791 | 792 |
| |
792 | 793 |
| |
793 | 794 |
| |
| 795 | + | |
794 | 796 |
| |
795 | 797 |
| |
796 | 798 |
| |
| |||
801 | 803 |
| |
802 | 804 |
| |
803 | 805 |
| |
| 806 | + | |
804 | 807 |
| |
805 | 808 |
| |
806 | 809 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2181 | 2181 |
| |
2182 | 2182 |
| |
2183 | 2183 |
| |
| 2184 | + | |
| 2185 | + | |
| 2186 | + | |
| 2187 | + | |
| 2188 | + | |
| 2189 | + | |
| 2190 | + | |
| 2191 | + | |
| 2192 | + | |
| 2193 | + | |
| 2194 | + | |
| 2195 | + | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
| 2201 | + | |
| 2202 | + | |
2184 | 2203 |
| |
2185 | 2204 |
| |
2186 | 2205 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5380 | 5380 |
| |
5381 | 5381 |
| |
5382 | 5382 |
| |
| 5383 | + | |
| 5384 | + | |
| 5385 | + | |
| 5386 | + | |
| 5387 | + | |
| 5388 | + | |
| 5389 | + | |
| 5390 | + | |
| 5391 | + | |
| 5392 | + | |
| 5393 | + | |
| 5394 | + | |
| 5395 | + | |
| 5396 | + | |
| 5397 | + | |
5383 | 5398 |
| |
5384 | 5399 |
| |
5385 | 5400 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
4054 | 4054 |
| |
4055 | 4055 |
| |
4056 | 4056 |
| |
| 4057 | + | |
| 4058 | + | |
| 4059 | + | |
| 4060 | + | |
| 4061 | + | |
| 4062 | + | |
| 4063 | + | |
| 4064 | + | |
| 4065 | + | |
| 4066 | + | |
| 4067 | + | |
| 4068 | + | |
| 4069 | + | |
4057 | 4070 |
| |
4058 | 4071 |
| |
4059 | 4072 |
| |
|
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
136 | 136 |
| |
137 | 137 |
| |
138 | 138 |
| |
| 139 | + | |
| 140 | + | |
| 141 | + | |
139 | 142 |
| |
140 | 143 |
| |
141 | 144 |
| |
|
0 commit comments
Comments
(0)