export function classifySensitivePath(filePath) {
    const parts = filePath
        .replace(/\\/g, "/")
        .split("/")
        .map((part) => part.trim())
        .filter(Boolean);
    const base = parts.at(-1) ?? "";
    if (/^\.env(?:\..*)?$/u.test(base))
        return "env";
    if (/^(?:\.npmrc|\.pypirc|\.netrc)$/u.test(base))
        return "credential";
    if (/\.(?:pem|key|p12|pfx)$/iu.test(base))
        return "credential";
    if (parts.includes(".ssh") || parts.includes(".aws"))
        return "credential";
    if (parts.includes(".docker")) {
        if (base === "config.json")
            return "credential";
        if (parts.includes("contexts") && base === "meta.json")
            return "credential";
    }
    if (parts.includes(".best-agent") &&
        /^(?:cli-state|config|credentials|provider-state|provider-config)\.json$/u.test(base)) {
        return "credential";
    }
    if (parts.includes(".dimcode")) {
        if (/^(?:cli-state|provider-state|provider-config|credentials|config|auth|mcp)\.json$/u.test(base)) {
            return "credential";
        }
        if (parts.includes("tool-results")) {
            return "credential";
        }
    }
    const configIndex = parts.lastIndexOf(".config");
    if (configIndex >= 0 && parts.length > configIndex + 2 && base === "credentials") {
        return "credential";
    }
    return undefined;
}
//# sourceMappingURL=sensitive-resource-policy.js.map