import type { ASTNode, Rule, AnalysisContext } from "../types.js"; /** * Rule that detects usage of tx.origin for authentication * * Security Issue: tx.origin should not be used for authorization because it represents * the original external account that started the transaction chain, not the immediate * caller. This makes contracts vulnerable to phishing attacks where a malicious * contract can trick users into calling it, which then calls the target contract * with the user's tx.origin. * * Recommendation: Use msg.sender instead of tx.origin for authorization checks. */ export declare class NoTxOriginRule implements Rule { readonly id = "no-tx-origin"; readonly description = "Avoid using tx.origin for authorization (use msg.sender instead)"; readonly severity: "warning"; apply(ast: ASTNode, context: AnalysisContext): void; private checkMemberAccess; } //# sourceMappingURL=no-tx-origin.d.ts.map