/**
 * Forbidden-commands guard — blocks bash commands matching dangerous patterns
 * before they reach the shell.
 *
 * Hardcoded default patterns are ALWAYS active regardless of settings.
 * Users can add additional patterns via settings.forbiddenCommands.
 *
 * Commands are split on shell operators (&&, ||, ;, |, &) and each segment
 * is checked independently. Default patterns are anchored to the start of
 * each segment (^) so they only match commands that *begin with* the dangerous
 * command, not commands that merely *mention* the pattern in string literals
 * or arguments.
 *
 * To avoid false positives from operators inside quoted strings, content
 * within single/double quotes is masked before splitting. To catch subshell
 * wrappers like $(cmd) and (cmd), leading wrapper characters are stripped
 * from each segment before pattern matching.
 */
/**
 * Check whether a command matches any forbidden pattern.
 *
 * The command is split on shell operators (&&, ||, ;, |) with quoted content
 * masked to avoid false splits. Each segment is then stripped of subshell
 * wrappers ($(...), (...), `...`) and checked against patterns. Default
 * patterns are ^-anchored so they only match commands that start with the
 * dangerous command prefix.
 *
 * @returns The first matching pattern, or `undefined` if the command is allowed.
 */
export declare function isForbiddenCommand(command: string, extraPatterns?: string[]): string | undefined;
/**
 * Extract file paths from a command that executes a script file.
 * Detects: `bash file`, `sh file`, `source file`, `. file`, and input
 * redirects like `bash < file`.
 *
 * Returns an array of file paths (usually 0 or 1). Does not check whether
 * the files exist — the caller handles that.
 *
 * @returns Array of script file paths referenced by the command.
 */
export declare function extractScriptPaths(command: string): string[];
/**
 * Check file content line-by-line for forbidden commands.
 * Each non-empty, non-comment line is passed through `isForbiddenCommand`.
 *
 * This is a pure function — the caller is responsible for reading the file
 * and passing the content string.
 *
 * @returns The first match with pattern, line number, and line text, or undefined.
 */
export declare function checkScriptContent(content: string, extraPatterns?: string[]): {
    pattern: string;
    line: number;
    text: string;
} | undefined;
//# sourceMappingURL=forbidden-commands.d.ts.map