PKCE Downgrade만 체킹한다고요? 아뇨 이제 PKCE가 있는지도 확인할겁니다.

이거도 좀 줄이고
This commit is contained in:
imnyang 2025-05-25 20:55:19 +09:00
commit 2e1eb7a3ab
4 changed files with 102 additions and 119 deletions

View file

@ -2,13 +2,13 @@ import type { SDK, DefineAPI } from "caido:plugin";
import type { Request } from "caido:utils";
import { ImplicitGrantController } from "./controller/implictGrant";
import { AuthZCodeGrantController } from "./controller/authZCodeGrant";
import { PKCEDowngradeCheck } from "./controller/PKCEDowngradeCheck";
import { PKCECheck } from "./controller/PKCECheck";
export type API = DefineAPI<{}>;
const implicitGrantController = new ImplicitGrantController();
const authZCodeGrantController = new AuthZCodeGrantController();
const pkceDowngradeCheck = new PKCEDowngradeCheck();
const pkceCheck = new PKCECheck();
// function matchSSORequest(req: Request): boolean {
// const raw = req.getRaw().toString();
@ -35,7 +35,7 @@ export function init(sdk: SDK<API>) {
implicitGrantController.testReq(req);
if (result) {
await pkceDowngradeCheck.test(sdk, req);
await pkceCheck.test(sdk, req);
await sdk.findings.create({
title: "Possible SSO Request Detected",