(body: string)
| 287 | }; |
| 288 | |
| 289 | const redactTokenEndpointBody = (body: string): string => |
| 290 | body |
| 291 | .replaceAll( |
| 292 | /("(?:access_token|refresh_token|id_token|client_secret)"\s*:\s*")[^"]*(")/gi, |
| 293 | "$1[redacted]$2", |
| 294 | ) |
| 295 | .replaceAll( |
| 296 | /((?:access_token|refresh_token|id_token|client_secret|code)=)[^&\s]*/gi, |
| 297 | "$1[redacted]", |
| 298 | ); |
| 299 | |
| 300 | const tokenEndpointHttpSummary = async (response: Response): Promise<string> => { |
| 301 | const status = `HTTP ${response.status}${response.statusText ? ` ${response.statusText}` : ""}`; |
no outgoing calls
no test coverage detected