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:
Amirul Islam Redwan71
2026-11-27 03:24:39 +06:00
parent 5d296a82f1
commit c827fdfee6
29 changed files with 2151 additions and 482 deletions
+1
View File
@@ -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
View File
@@ -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,
});
}
+1
View File
@@ -25,6 +25,7 @@ export class RedxAdapter implements CourierAdapter {
"Content-Type": "application/json",
},
timeout: 15000,
maxRedirects: 0,
});
}
+1
View File
@@ -25,6 +25,7 @@ export class SteadfastAdapter implements CourierAdapter {
"Content-Type": "application/json",
},
timeout: 10000,
maxRedirects: 0,
});
}