/
TON618OFF
/
FinalPWHTML
Обзор
Документация
Войти
/
TON618OFF
/
FinalPWHTML
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
node_modules/@tinyhttp/proxy-addr/dist/index.d.ts
37 строк
1 KB
TON618OFF
не ну это ваще
23 июн 2024, 00:30
23 июн 2024, 00:30
e27ae20
Код
Авторство
О чём код?
/// <reference types="node" /> import type { IncomingMessage } from 'node:http'; import { IPv6, IPv4 } from 'ipaddr.js'; type Req = Pick<IncomingMessage, 'headers' | 'socket'>; type Trust = ((addr: string, i: number) => boolean) | number[] | string[] | string; /** * Get all addresses in the request, optionally stopping * at the first untrusted. * * @param request * @param trust */ declare function alladdrs(req: Req, trust: Trust): string[]; /** * Compile argument into trust function. * * @param val */ declare function compile(val: string | string[] | number[]): (addr: string) => boolean; /** * Parse IP notation string into range subnet. * * @param {String} note * @private */ export declare function parseIPNotation(note: string): [IPv4 | IPv6, string | number]; /** * Determine address of proxied request. * * @param request * @param trust * @public */ export declare function proxyaddr(req: Req, trust: Trust): string; export { alladdrs as all }; export { compile }; //# sourceMappingURL=index.d.ts.map