This commit is contained in:
2025-08-18 23:06:34 +08:00
parent 0bc04fb659
commit ed18af0cad
1926 changed files with 275098 additions and 0 deletions

22
package/node_modules/cidr-regex/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,22 @@
Copyright (c) silverwind
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

15
package/node_modules/cidr-regex/dist/index.js generated vendored Normal file
View File

@@ -0,0 +1,15 @@
import ipRegex from "ip-regex";
const defaultOpts = { exact: false };
const v4str = `${ipRegex.v4().source}\\/(3[0-2]|[12]?[0-9])`;
const v6str = `${ipRegex.v6().source}\\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])`;
const v4exact = new RegExp(`^${v4str}$`);
const v6exact = new RegExp(`^${v6str}$`);
const v46exact = new RegExp(`(?:^${v4str}$)|(?:^${v6str}$)`);
const cidrRegex = ({ exact } = defaultOpts) => exact ? v46exact : new RegExp(`(?:${v4str})|(?:${v6str})`, "g");
const v4 = cidrRegex.v4 = ({ exact } = defaultOpts) => exact ? v4exact : new RegExp(v4str, "g");
const v6 = cidrRegex.v6 = ({ exact } = defaultOpts) => exact ? v6exact : new RegExp(v6str, "g");
export {
cidrRegex as default,
v4,
v6
};

40
package/node_modules/cidr-regex/package.json generated vendored Normal file
View File

@@ -0,0 +1,40 @@
{
"name": "cidr-regex",
"version": "4.1.1",
"description": "Regular expression for matching IP addresses in CIDR notation",
"author": "silverwind <me@silverwind.io>",
"contributors": [
"Felipe Apostol <flipjs.io@gmail.com> (http://flipjs.io/)"
],
"repository": "silverwind/cidr-regex",
"license": "BSD-2-Clause",
"type": "module",
"sideEffects": false,
"main": "./dist/index.js",
"exports": "./dist/index.js",
"types": "./dist/index.d.ts",
"files": [
"dist"
],
"engines": {
"node": ">=14"
},
"dependencies": {
"ip-regex": "^5.0.0"
},
"devDependencies": {
"@types/node": "20.12.12",
"eslint": "8.57.0",
"eslint-config-silverwind": "85.1.4",
"eslint-config-silverwind-typescript": "3.2.7",
"typescript": "5.4.5",
"typescript-config-silverwind": "4.3.2",
"updates": "16.1.1",
"versions": "12.0.2",
"vite": "5.2.11",
"vite-config-silverwind": "1.1.2",
"vite-plugin-dts": "3.9.1",
"vitest": "1.6.0",
"vitest-config-silverwind": "9.0.6"
}
}