Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@vinxi/listhen

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vinxi/listhen - npm Package Compare versions

Comparing version 1.5.5 to 1.5.6

dist/shared/listhen.994822d6.d.cts

2

dist/cli.d.ts
import * as citty from 'citty';
import { ParsedArgs } from 'citty';
import { L as ListenOptions } from './shared/listhen.10ba2b37.js';
import { L as ListenOptions } from './shared/listhen.994822d6.js';
import 'node:http';

@@ -5,0 +5,0 @@ import 'node:https';

import { RequestListener } from 'node:http';
import { L as ListenOptions, a as Listener } from './shared/listhen.10ba2b37.js';
export { C as Certificate, G as GetURLOptions, H as HTTPSOptions, b as ListenURL, S as ShowURLOptions } from './shared/listhen.10ba2b37.js';
import { L as ListenOptions, a as Listener, H as HTTPSOptions, C as Certificate } from './shared/listhen.994822d6.js';
export { G as GetURLOptions, b as ListenURL, S as ShowURLOptions } from './shared/listhen.994822d6.js';
import { ConsolaInstance } from 'consola';
import * as h3 from 'h3';
import forge from 'node-forge';
import 'node:https';

@@ -39,2 +40,123 @@ import 'node:net';

export { type DevServerOptions, ListenOptions, Listener, type WatchOptions, createDevServer, listen, listenAndWatch };
interface CertificateOptions {
validityDays: number;
subject: forge.pki.CertificateField[];
issuer: forge.pki.CertificateField[];
extensions: any[];
}
interface CommonCertificateOptions {
commonName?: string;
countryCode?: string;
state?: string;
locality?: string;
organization?: string;
organizationalUnit?: string;
emailAddress?: string;
domains?: string[];
}
interface SigningOptions {
signingKey?: string;
signingKeyCert?: string;
signingKeyPassphrase?: string;
}
interface TLSCertOptions extends CommonCertificateOptions, SigningOptions {
bits?: number;
validityDays?: number;
passphrase?: string;
}
declare function resolveCertificate(options: HTTPSOptions): Promise<Certificate>;
declare function generateCertificates(options: TLSCertOptions): Promise<{
cert: Certificate;
ca: Certificate;
}>;
declare function resolveCert(options: HTTPSOptions): Promise<Certificate>;
declare function resolvePfx(options: HTTPSOptions): Promise<forge.pkcs12.Pkcs12Pfx>;
declare function createCertificateInfo(options: CommonCertificateOptions): {
attributes: {
name: string;
value: string;
}[];
extensions: ({
name: string;
cA: boolean;
critical: boolean;
digitalSignature?: undefined;
keyEncipherment?: undefined;
serverAuth?: undefined;
clientAuth?: undefined;
altNames?: undefined;
} | {
name: string;
digitalSignature: boolean;
keyEncipherment: boolean;
critical: boolean;
cA?: undefined;
serverAuth?: undefined;
clientAuth?: undefined;
altNames?: undefined;
} | {
name: string;
serverAuth: boolean;
clientAuth: boolean;
cA?: undefined;
critical?: undefined;
digitalSignature?: undefined;
keyEncipherment?: undefined;
altNames?: undefined;
} | {
name: string;
altNames: ({
type: number;
ip: string;
value?: undefined;
} | {
type: number;
value: string;
ip?: undefined;
})[];
cA?: undefined;
critical?: undefined;
digitalSignature?: undefined;
keyEncipherment?: undefined;
serverAuth?: undefined;
clientAuth?: undefined;
})[];
};
declare function createCaInfo(options: TLSCertOptions): {
attributes: {
name: string;
value: string;
}[];
extensions: ({
name: string;
cA: boolean;
critical: boolean;
keyCertSign?: undefined;
} | {
name: string;
keyCertSign: boolean;
critical: boolean;
cA?: undefined;
})[];
};
declare function generateTLSCert(options: TLSCertOptions): Promise<Certificate>;
declare function generateCACert(options?: TLSCertOptions): Promise<Certificate>;
declare function signCertificate(options: SigningOptions, cert: forge.pki.Certificate): void;
declare function createCertificateFromKeyPair(keyPair: forge.pki.KeyPair, options: CertificateOptions): forge.pki.Certificate;
declare function generateKeyPair(bits?: number): Promise<forge.pki.KeyPair>;
declare function generateCert(options: TLSCertOptions & CertificateOptions): Promise<Certificate>;
declare const _private: {
generateCert: typeof generateCert;
generateKeyPair: typeof generateKeyPair;
generateCACert: typeof generateCACert;
generateTLSCert: typeof generateTLSCert;
createCaInfo: typeof createCaInfo;
createCertificateInfo: typeof createCertificateInfo;
signCertificate: typeof signCertificate;
createCertificateFromKeyPair: typeof createCertificateFromKeyPair;
resolveCert: typeof resolveCert;
resolvePfx: typeof resolvePfx;
generateCertificates: typeof generateCertificates;
};
export { Certificate, type CertificateOptions, type CommonCertificateOptions, type DevServerOptions, HTTPSOptions, ListenOptions, Listener, type SigningOptions, type TLSCertOptions, type WatchOptions, _private, createDevServer, listen, listenAndWatch, resolveCertificate };
{
"name": "@vinxi/listhen",
"version": "1.5.5",
"version": "1.5.6",
"description": "👂 Elegant HTTP Listener",

@@ -37,3 +37,3 @@ "repository": "unjs/listhen",

"listhen": "node ./scripts/listhen.mjs",
"play": "node ./scripts/listhen.mjs -w ./playground",
"play": "node ./scripts/listhen.mjs --ws -w ./playground",
"release": "pnpm test && pnpm build && changelogen --release && pnpm publish && git push --follow-tags",

@@ -45,32 +45,32 @@ "test": "pnpm lint && vitest run --coverage"

"@parcel/watcher-wasm": "2.3.0",
"citty": "^0.1.4",
"clipboardy": "^3.0.0",
"citty": "^0.1.5",
"clipboardy": "^4.0.0",
"consola": "^3.2.3",
"defu": "^6.1.2",
"get-port-please": "^3.1.1",
"h3": "^1.8.1",
"defu": "^6.1.4",
"get-port-please": "^3.1.2",
"h3": "^1.10.0",
"http-shutdown": "^1.2.2",
"jiti": "^1.20.0",
"mlly": "^1.4.2",
"jiti": "^1.21.0",
"mlly": "^1.5.0",
"node-forge": "^1.3.1",
"pathe": "^1.1.1",
"std-env": "^3.4.3",
"ufo": "^1.3.0",
"untun": "^0.1.2",
"pathe": "^1.1.2",
"std-env": "^3.7.0",
"ufo": "^1.3.2",
"untun": "^0.1.3",
"uqr": "^0.1.2"
},
"devDependencies": {
"@types/node": "^20.6.3",
"@types/node-forge": "^1.3.5",
"@vitest/coverage-v8": "^0.34.4",
"@types/node": "^20.11.0",
"@types/node-forge": "^1.3.11",
"@vitest/coverage-v8": "^1.2.0",
"changelogen": "^0.5.5",
"eslint": "^8.49.0",
"eslint": "^8.56.0",
"eslint-config-unjs": "^0.2.1",
"ip-regex": "^5.0.0",
"prettier": "^3.0.3",
"typescript": "^5.2.2",
"prettier": "^3.2.2",
"typescript": "^5.3.3",
"unbuild": "^2.0.0",
"vitest": "^0.34.4"
"vitest": "^1.2.0"
},
"packageManager": "pnpm@8.7.4"
"packageManager": "pnpm@8.14.1"
}

@@ -60,3 +60,3 @@ # 👂 listhen

app.use("/", () => "Hello world!");
app.use("/", eventHandler(() => "Hello world!"));
```

@@ -63,0 +63,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc