/// <reference types="node" />
import net from 'net';
import { ISocksServer, ProxyServers, SetProxyServerOptions, Socks5ProxyOptions } from '../types';
import { AddressInfo } from '../types/utils';
/**
 * The following RFCs may be useful as background:
 *
 * https://www.ietf.org/rfc/rfc1928.txt - NO_AUTH SOCKS5
 * https://www.ietf.org/rfc/rfc1929.txt - USERNAME/PASSWORD SOCKS5
 *
 **/
export declare class SocksServer implements ISocksServer {
    private _server;
    private options;
    private activeSessions;
    private destinationSockets;
    private syncDestinationSocketInterval;
    constructor(options: Socks5ProxyOptions);
    on: (event: string, listener: (...args: any[]) => void) => net.Server;
    listen: (...args: any[]) => net.Server;
    listenAsync: (port: number, host?: string) => Promise<void>;
    close: (...args: any[]) => net.Server;
    getConnections: (cb: (error: Error | null, count: number) => void) => void;
    setProxyServer: ({ address, port, shouldUseProxy }: SetProxyServerOptions) => void;
    setProxyServers: (proxyServers: ProxyServers) => void;
    getProxyServers: () => import("../types/utils").ProxyPoolOptions | undefined;
    set shouldBlockPrivateAddresses(value: boolean);
    get shouldBlockPrivateAddresses(): boolean;
    setShouldBlockRequest(shouldBlockRequest: (data: AddressInfo) => boolean): void;
    get server(): net.Server;
}
export declare function createSocks5ProxyServer(options?: Socks5ProxyOptions): SocksServer;
export * as EVENTS from './events';
//# sourceMappingURL=index.d.ts.map