security(v2.7.2): remediate all 3 Critical P0 & 5 High P1 audit findings (fail-closed auth, webhook hardening + replay protection, auth-first BYOK + SSRF allowlist, minimal public tracker DTO, atomic+DB idempotency, 0 npm vulnerabilities, CI gate)
This commit is contained in:
@@ -27,6 +27,7 @@ export class PaperflyAdapter implements CourierAdapter {
|
||||
this.client = axios.create({
|
||||
baseURL: baseUrl,
|
||||
timeout: 15000,
|
||||
maxRedirects: 0,
|
||||
headers: { "Content-Type": "application/json" },
|
||||
});
|
||||
}
|
||||
|
||||
+12
-7
@@ -52,13 +52,17 @@ export class PathaoAdapter implements CourierAdapter {
|
||||
return this.accessToken;
|
||||
}
|
||||
|
||||
const response = await axios.post(`${this.baseUrl}/aladdin/api/v1/issue-token`, {
|
||||
client_id: this.clientId,
|
||||
client_secret: this.clientSecret,
|
||||
username: this.username,
|
||||
password: this.password,
|
||||
grant_type: "password",
|
||||
});
|
||||
const response = await axios.post(
|
||||
`${this.baseUrl}/aladdin/api/v1/issue-token`,
|
||||
{
|
||||
client_id: this.clientId,
|
||||
client_secret: this.clientSecret,
|
||||
username: this.username,
|
||||
password: this.password,
|
||||
grant_type: "password",
|
||||
},
|
||||
{ timeout: 12000, maxRedirects: 0 }
|
||||
);
|
||||
|
||||
this.accessToken = response.data.access_token;
|
||||
this.tokenExpiresAt = now + (response.data.expires_in || 3600) * 1000;
|
||||
@@ -74,6 +78,7 @@ export class PathaoAdapter implements CourierAdapter {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
timeout: 12000,
|
||||
maxRedirects: 0,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@ export class RedxAdapter implements CourierAdapter {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
timeout: 15000,
|
||||
maxRedirects: 0,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@ export class SteadfastAdapter implements CourierAdapter {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
timeout: 10000,
|
||||
maxRedirects: 0,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user