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

@types/koa-sslify

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/koa-sslify - npm Package Compare versions

Comparing version 2.1.0 to 4.0.0

83

koa-sslify/index.d.ts

@@ -1,25 +0,80 @@

// Type definitions for koa-sslify 2.1
// Type definitions for koa-sslify 4.0
// Project: https://github.com/turboMaCk/koa-sslify#readme
// Definitions by: Matthew Bull <https://github.com/wingsbob>
// Mihkel Sokk <https://github.com/msokk>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
import * as koa from 'koa';
import * as koa from "koa";
declare namespace sslify {
interface Options {
trustProtoHeader?: boolean;
trustAzureHeader?: boolean;
port?: number;
hostname?: string;
ignoreUrl?: boolean;
temporary?: boolean;
redirectMethods?: string[];
internalRedirectMethods?: string[];
specCompliantDisallow?: boolean;
}
interface Options {
/**
* Function used to test if request is secure
*/
resolver?: (ctx: koa.Context) => boolean;
/**
* Hostname for redirect (uses request host if not set)
*/
hostname?: string;
/**
* Port of HTTPS server
*/
port?: number;
/**
* Avoid :443 port in redirect url
*/
skipDefaultPort?: boolean;
/**
* Ignore url path (redirect to domain)
*/
ignoreUrl?: boolean;
/**
* Temporary mode (use 307 Temporary Redirect)
*/
temporary?: boolean;
/**
* Whitelist methods that should be redirected
*/
redirectMethods?: string[];
/**
* Status returned for disallowed methods
*/
disallowStatus?: number;
}
/**
* Default HTTPS resolver
* This works when using node.js TLS support
*/
function httpsResolver(ctx: koa.Context): boolean;
/**
* x-forwarded-proto header resolver
* common for heroku gcp (ingress) etc
*/
function xForwardedProtoResolver(ctx: koa.Context): boolean;
/**
* Azure resolver
* Azure is using `x-att-ssl` header
*/
function azureResolver(ctx: koa.Context): boolean;
/**
* Custom proto header factory
*/
function customProtoHeaderResolver(
header: string
): (ctx: koa.Context) => boolean;
/**
* Resolver for `Forwarded` header
* see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Forwarded
*/
function forwardedResolver(ctx: koa.Context): boolean;
}
declare function sslify(options: sslify.Options): koa.Middleware;
declare function sslify(options?: sslify.Options): koa.Middleware;
export = sslify;

13

koa-sslify/package.json
{
"name": "@types/koa-sslify",
"version": "2.1.0",
"version": "4.0.0",
"description": "TypeScript definitions for koa-sslify",

@@ -11,8 +11,15 @@ "license": "MIT",

"githubUsername": "wingsbob"
},
{
"name": "Mihkel Sokk",
"url": "https://github.com/msokk",
"githubUsername": "msokk"
}
],
"main": "",
"types": "index",
"repository": {
"type": "git",
"url": "https://www.github.com/DefinitelyTyped/DefinitelyTyped.git"
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
"directory": "types/koa-sslify"
},

@@ -23,4 +30,4 @@ "scripts": {},

},
"typesPublisherContentHash": "b5a37decac7747d05ee68de1ac605a99a717132985ff4f1ce583b4fa9931d684",
"typesPublisherContentHash": "369edeeb029161e3fede52593bd67ae0df7c5542a02c1db9167c7fd36e8c5e57",
"typeScriptVersion": "2.3"
}

@@ -5,13 +5,13 @@ # Installation

# Summary
This package contains type definitions for koa-sslify (https://github.com/turboMaCk/koa-sslify#readme).
This package contains type definitions for koa-sslify ( https://github.com/turboMaCk/koa-sslify#readme ).
# Details
Files were exported from https://www.github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/koa-sslify
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/koa-sslify
Additional Details
* Last updated: Mon, 11 Dec 2017 19:14:19 GMT
* Dependencies: koa
* Last updated: Thu, 28 Feb 2019 02:44:47 GMT
* Dependencies: @types/koa
* Global values: none
# Credits
These definitions were written by Matthew Bull <https://github.com/wingsbob>.
These definitions were written by Matthew Bull <https://github.com/wingsbob>, Mihkel Sokk <https://github.com/msokk>.

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