Commit ab7dd68
committed
✨(backend) allow prefixing resource server scopes
When declaring scopes with our OIDC provider, they require us to prefix
each scope with our application name. This is to prevent reserving generic scopes
like rooms:list for only our app, as they manage a large federation.
I’m proposing a workaround where, if a resource server prefix is detected in
the scope, it’s stripped out. This solution is simple and sufficient in my opinion.
Since the scopes are defined in the database, I don’t want to update them directly.
Additionally, each self-hosted instance may have a different application name,
so the prefix should be configurable via a Django setting.1 parent c7f5dab commit ab7dd68
File tree
3 files changed
+15
-2
lines changed- src/backend
- core
- external_api
- tests
- meet
3 files changed
+15
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
6 | 8 | | |
7 | 9 | | |
8 | 10 | | |
| |||
55 | 57 | | |
56 | 58 | | |
57 | 59 | | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
58 | 66 | | |
59 | 67 | | |
60 | 68 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
373 | 373 | | |
374 | 374 | | |
375 | 375 | | |
| 376 | + | |
376 | 377 | | |
377 | 378 | | |
378 | 379 | | |
| |||
389 | 390 | | |
390 | 391 | | |
391 | 392 | | |
392 | | - | |
| 393 | + | |
393 | 394 | | |
394 | 395 | | |
395 | 396 | | |
| |||
489 | 490 | | |
490 | 491 | | |
491 | 492 | | |
| 493 | + | |
492 | 494 | | |
493 | 495 | | |
494 | 496 | | |
| |||
505 | 507 | | |
506 | 508 | | |
507 | 509 | | |
508 | | - | |
| 510 | + | |
509 | 511 | | |
510 | 512 | | |
511 | 513 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
538 | 538 | | |
539 | 539 | | |
540 | 540 | | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
541 | 544 | | |
542 | 545 | | |
543 | 546 | | |
| |||
0 commit comments