export interface UPnPBinding { remotehost: string; host: string; port: number; } export declare class UpnpProvider { private portStart; private portEnd; private identifier; private upnpInterval; private ttl; private logger?; private host; private currentConfig; private interval; private client; constructor(portStart: number, portEnd: number, identifier: string, upnpInterval?: number, ttl?: number, logger?: any, host?: string); checkUPnPisAvailable(): Promise; getCurrentConfig(): UPnPBinding | null; getUpnpDescription(): string; /** * Always open the same port during an execution of Duniter. * @returns { host:string, port:number } */ openPort(): Promise<{ host: string; port: number; }>; startRegular(): Promise<{ host: string; port: number; available: boolean; }>; stopRegular(): void; static getLocalIP(client: any): Promise; static getRemoteIP(client: any): Promise; private getAvailablePort; static getUPnPMappings(client: any): Promise; /** * Apparently on computers with both Wi-Fi and Ethernet, UPnP fails to open the port. * Giving the priority to Ethernet seems to fix the problem. * @param family */ private getBestHostForUPnP; }