import { VlanManager, type IMacVlanMapping, type IVlanManagerConfig } from './classes.vlan.manager.js';
import { AccountingManager, type IAccountingManagerConfig } from './classes.accounting.manager.js';
/**
 * RADIUS client (NAS) configuration
 */
export interface IRadiusClient {
    /** Client name for identification */
    name: string;
    /** IP address or CIDR range */
    ipRange: string;
    /** Shared secret for this client */
    secret: string;
    /** Optional description */
    description?: string;
    /** Whether this client is enabled */
    enabled: boolean;
}
/**
 * RADIUS server configuration
 */
export interface IRadiusServerConfig {
    /** Authentication port (default: 1812) */
    authPort?: number;
    /** Accounting port (default: 1813) */
    acctPort?: number;
    /** Bind address (default: 0.0.0.0) */
    bindAddress?: string;
    /** NAS clients configuration */
    clients: IRadiusClient[];
    /** VLAN assignment configuration */
    vlanAssignment?: IVlanManagerConfig & {
        /** Static MAC to VLAN mappings */
        mappings?: Array<Omit<IMacVlanMapping, 'createdAt' | 'updatedAt'>>;
    };
    /** Accounting configuration */
    accounting?: IAccountingManagerConfig & {
        /** Whether accounting is enabled */
        enabled: boolean;
    };
}
/**
 * RADIUS authentication result
 */
export interface IRadiusAuthResult {
    /** Whether authentication was successful */
    success: boolean;
    /** Reject reason (if not successful) */
    rejectReason?: string;
    /** Reply message to send to client */
    replyMessage?: string;
    /** Session timeout in seconds */
    sessionTimeout?: number;
    /** Idle timeout in seconds */
    idleTimeout?: number;
    /** VLAN to assign */
    vlanId?: number;
    /** Framed IP address to assign */
    framedIpAddress?: string;
}
/**
 * Authentication request data from RADIUS
 */
export interface IAuthRequestData {
    username: string;
    password?: string;
    nasIpAddress: string;
    nasPort?: number;
    nasPortType?: string;
    nasIdentifier?: string;
    calledStationId?: string;
    callingStationId?: string;
    serviceType?: string;
    framedMtu?: number;
}
/**
 * RADIUS Server wrapper that provides:
 * - MAC Authentication Bypass (MAB) for network devices
 * - VLAN assignment based on MAC address
 * - Accounting for session tracking and billing
 * - Integration with SmartProxy routing
 */
export declare class RadiusServer {
    private radiusServer?;
    private vlanManager;
    private accountingManager;
    private config;
    private running;
    private stats;
    constructor(config: IRadiusServerConfig);
    /**
     * Start the RADIUS server
     */
    start(): Promise<void>;
    /**
     * Stop the RADIUS server
     */
    stop(): Promise<void>;
    /**
     * Handle authentication request
     */
    private handleAuthentication;
    /**
     * Handle accounting request
     */
    private handleAccounting;
    /**
     * Perform MAC Authentication Bypass
     */
    private performMabAuthentication;
    /**
     * Extract MAC address from authentication data
     */
    private extractMacAddress;
    /**
     * Check if a string looks like a MAC address
     */
    private looksLikeMac;
    /**
     * Normalize MAC address format
     */
    private normalizeMac;
    /**
     * Build client secrets map from configuration
     */
    private buildClientSecretsMap;
    /**
     * Add a RADIUS client
     */
    addClient(client: IRadiusClient): Promise<void>;
    /**
     * Remove a RADIUS client
     */
    removeClient(name: string): boolean;
    /**
     * Get configured clients
     */
    getClients(): IRadiusClient[];
    /**
     * Get VLAN manager for direct access to VLAN operations
     */
    getVlanManager(): VlanManager;
    /**
     * Get accounting manager for direct access to accounting operations
     */
    getAccountingManager(): AccountingManager;
    /**
     * Get server statistics
     */
    getStats(): {
        running: boolean;
        uptime: number;
        authRequests: number;
        authAccepts: number;
        authRejects: number;
        accountingRequests: number;
        activeSessions: number;
        vlanMappings: number;
        clients: number;
    };
    /**
     * Check if server is running
     */
    isRunning(): boolean;
}
