import { ChildProcess } from 'node:child_process';
export interface SSHCredentials {
    privateKey: string;
    /** Optional — when absent, standard public-key auth is used (no certificate) */
    certificate?: string;
}
export interface SSHConnectionOptions {
    rows?: number;
    cols?: number;
}
export interface SSHConnection {
    process: ChildProcess;
    cleanup: () => Promise<void>;
}
/**
 * Service for managing native SSH connections with certificate support
 * Uses native SSH command instead of ssh2 library to support SSH certificates
 */
export declare class NativeSSHConnectionService {
    private readonly logger;
    /**
     * Create a native SSH connection with certificate authentication
     *
     * @param host - Server IP or hostname
     * @param username - SSH username (typically 'root')
     * @param credentials - Private key and certificate
     * @param onData - Callback for stdout data
     * @param onError - Callback for errors
     * @param onClose - Callback when connection closes
     * @param options - Connection options (terminal size)
     * @returns SSH connection object with cleanup function
     */
    createConnection(host: string, username: string, credentials: SSHCredentials, onData: (data: string) => void, onError: (error: Error) => void, onClose: () => void, options?: SSHConnectionOptions): Promise<SSHConnection>;
    /**
     * Execute a single command over SSH and return stdout.
     * Uses plain private-key auth (no certificate) — suitable for bootstrap key access.
     */
    execCommand(host: string, username: string, privateKey: string, command: string, timeoutMs?: number): Promise<string>;
    /**
     * Write data to SSH stdin
     */
    writeData(sshProcess: ChildProcess, data: string): void;
    /**
     * Resize terminal using stty command
     * Sends stty command to the remote shell to update terminal size
     */
    resizeTerminal(sshProcess: ChildProcess, rows: number, cols: number): void;
}
