Commit 0d80e93
Validate STS expiry on direct-WIF path and tighten IAM check to <=
- Direct-WIF (no service account) now rejects STS tokens with ExpiresIn
<= 5 minutes, preventing cache-immediately-expired loops
- IAM path uses <= instead of < for the 5-minute threshold, fixing the
edge case where remaining == 5m caches as immediately expired
- Add tests for zero expiry and exactly-5-minutes boundary
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 4c9d3c3 commit 0d80e93
2 files changed
Lines changed: 38 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
743 | 743 | | |
744 | 744 | | |
745 | 745 | | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
746 | 750 | | |
747 | 751 | | |
748 | | - | |
| 752 | + | |
749 | 753 | | |
750 | 754 | | |
751 | 755 | | |
| |||
800 | 804 | | |
801 | 805 | | |
802 | 806 | | |
803 | | - | |
| 807 | + | |
804 | 808 | | |
805 | 809 | | |
806 | 810 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1190 | 1190 | | |
1191 | 1191 | | |
1192 | 1192 | | |
| 1193 | + | |
| 1194 | + | |
| 1195 | + | |
| 1196 | + | |
| 1197 | + | |
| 1198 | + | |
| 1199 | + | |
| 1200 | + | |
| 1201 | + | |
| 1202 | + | |
| 1203 | + | |
| 1204 | + | |
| 1205 | + | |
| 1206 | + | |
| 1207 | + | |
| 1208 | + | |
| 1209 | + | |
| 1210 | + | |
| 1211 | + | |
| 1212 | + | |
| 1213 | + | |
| 1214 | + | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
1193 | 1225 | | |
1194 | 1226 | | |
1195 | 1227 | | |
| |||
0 commit comments