Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
@types/hapi-auth-bearer-token
Advanced tools
npm install --save @types/hapi-auth-bearer-token
This package contains type definitions for hapi-auth-bearer-token (https://github.com/johnbrett/hapi-auth-bearer-token).
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/hapi-auth-bearer-token.
// Type definitions for hapi-auth-bearer-token 6.1
// Project: https://github.com/johnbrett/hapi-auth-bearer-token
// Definitions by: Rodrigo Saboya <https://github.com/saboya>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// Minimum TypeScript Version: 4.9
import { AuthenticationData, Plugin, Request, ResponseToolkit } from "@hapi/hapi";
type ValidateReturn = AuthenticationData & { isValid: boolean };
declare module "@hapi/hapi" {
interface ServerAuth {
strategy(name: string, scheme: "bearer-access-token", options: BearerToken.SchemaOptions): void;
}
}
declare namespace BearerToken {
interface SchemaOptions {
validate: Validate;
accessTokenName?: string | undefined;
allowQueryToken?: boolean | undefined;
allowCookieToken?: boolean | undefined;
allowMultipleHeaders?: boolean | undefined;
allowChaining?: boolean | undefined;
tokenType?: string | undefined;
unauthorized?: ((message: string | null, scheme: string) => any) | undefined;
}
type Validate = (request: Request, token: string, h: ResponseToolkit) => Promise<ValidateReturn> | ValidateReturn;
}
declare var BearerToken: Plugin<{}>;
export = BearerToken;
These definitions were written by Rodrigo Saboya.
FAQs
TypeScript definitions for hapi-auth-bearer-token
We found that @types/hapi-auth-bearer-token demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.