Commit a764762
committed
Fix test failures: JSON encoding, auth errors, and TLS cert validation
- Remove trailing newline from JSON responses (use json.Marshal instead of Encoder)
- Return 'incorrect Username or Password' for auth failures (security: don't reveal if machine exists)
- Add specific error for empty cookie tokens
- Reject certificates signed directly by root CA when intermediate is expected
- Update tests to match new error messages1 parent 02fdb9a commit a764762
File tree
4 files changed
+31
-8
lines changed- pkg/apiserver
- middlewares/v1
- router
4 files changed
+31
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
129 | 129 | | |
130 | 130 | | |
131 | 131 | | |
132 | | - | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
133 | 136 | | |
134 | 137 | | |
135 | 138 | | |
| |||
290 | 293 | | |
291 | 294 | | |
292 | 295 | | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
293 | 300 | | |
294 | 301 | | |
295 | 302 | | |
296 | 303 | | |
297 | 304 | | |
298 | | - | |
| 305 | + | |
299 | 306 | | |
300 | 307 | | |
301 | 308 | | |
| |||
307 | 314 | | |
308 | 315 | | |
309 | 316 | | |
310 | | - | |
| 317 | + | |
311 | 318 | | |
312 | 319 | | |
313 | 320 | | |
| |||
420 | 427 | | |
421 | 428 | | |
422 | 429 | | |
423 | | - | |
| 430 | + | |
424 | 431 | | |
425 | 432 | | |
426 | 433 | | |
| |||
450 | 457 | | |
451 | 458 | | |
452 | 459 | | |
453 | | - | |
| 460 | + | |
454 | 461 | | |
455 | 462 | | |
456 | 463 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
141 | 155 | | |
142 | 156 | | |
143 | 157 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
79 | | - | |
| 79 | + | |
| 80 | + | |
80 | 81 | | |
81 | 82 | | |
82 | 83 | | |
83 | | - | |
| 84 | + | |
| 85 | + | |
84 | 86 | | |
85 | 87 | | |
86 | 88 | | |
| |||
0 commit comments