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

remix-auth-email-link

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remix-auth-email-link - npm Package Compare versions

Comparing version 1.4.1 to 1.4.2

2

build/index.d.ts

@@ -128,5 +128,5 @@ import type { SessionStorage } from '@remix-run/server-runtime';

authenticate(request: Request, sessionStorage: SessionStorage, options: AuthenticateOptions): Promise<User>;
getMagicLink(emailAddress: string, domainUrl: string, form: FormData): Promise<string>;
private getDomainURL;
private sendToken;
private getMagicLink;
private createMagicLinkPayload;

@@ -133,0 +133,0 @@ private encrypt;

@@ -117,2 +117,11 @@ "use strict";

}
async getMagicLink(emailAddress, domainUrl, form) {
const payload = this.createMagicLinkPayload(emailAddress, form);
const stringToEncrypt = JSON.stringify(payload);
const encryptedString = await this.encrypt(stringToEncrypt);
const url = new URL(domainUrl);
url.pathname = this.callbackURL;
url.searchParams.set(this.magicLinkSearchParam, encryptedString);
return url.toString();
}
getDomainURL(request) {

@@ -145,11 +154,2 @@ var _a;

}
async getMagicLink(emailAddress, domainUrl, form) {
const payload = this.createMagicLinkPayload(emailAddress, form);
const stringToEncrypt = JSON.stringify(payload);
const encryptedString = await this.encrypt(stringToEncrypt);
const url = new URL(domainUrl);
url.pathname = this.callbackURL;
url.searchParams.set(this.magicLinkSearchParam, encryptedString);
return url.toString();
}
createMagicLinkPayload(emailAddress, form) {

@@ -156,0 +156,0 @@ return {

{
"name": "remix-auth-email-link",
"version": "1.4.1",
"version": "1.4.2",
"main": "./build/index.js",

@@ -5,0 +5,0 @@ "types": "./build/index.d.ts",

# Email Link Strategy - Remix Auth
> This strategy is heavily based on **kcd** strategy present in the v2 of [Remix Auth](https://github.com/sergiodxa/remix-auth/blob/main/docs/strategies/kcd.md). The major difference being we are using `crypto-js` instead of `crypto` so that it can be deployed on CF.
> This strategy is heavily based on **kcd** strategy present in the [v2 of Remix Auth](https://github.com/sergiodxa/remix-auth/blob/v2.6.0/docs/strategies/kcd.md). The major difference being we are using `crypto-js` instead of `crypto` so that it can be deployed on CF.

@@ -5,0 +5,0 @@ The Email Link Strategy implements the authentication strategy used on [kentcdodds.com](https://kentcdodds.com).

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