New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

serverless-basic-authentication

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

serverless-basic-authentication - npm Package Compare versions

Comparing version 0.13.0 to 0.14.0

LICENSE

23

index.js
const fs = require('fs');
const chalk = require('chalk');
const path = require('path');

@@ -28,3 +29,3 @@ module.exports = class SetupBasicAuthentication {

this.serverless.cli.consoleLog(`Basic Authentication: ${chalk.yellow('Removing Symlink for Basic Authenticator')}`);
fs.unlinkSync(`${this.serverless.config.servicePath}/basic_auth.py`);
fs.unlinkSync(path.normalize(`${this.serverless.config.servicePath}/basic_auth.py`));
}

@@ -45,5 +46,19 @@

// append our auth.py file to the package
this.serverless.package.include.push(`${__dirname}/auth.py`);
fs.symlinkSync(`${__dirname}/basic_auth.py`, `${this.serverless.config.servicePath}/basic_auth.py`);
// append our basic_auth.py file to the package
this.serverless.package.include.push(path.normalize(`${__dirname}/basic_auth.py`));
try {
fs.symlinkSync(
path.normalize(`${__dirname}/basic_auth.py`),
path.normalize(`${this.serverless.config.servicePath}/basic_auth.py`)
);
} catch (error) {
if (error.errno === -4048 && error.code === 'EPERM') {
fs.copyFileSync(
path.normalize(`${__dirname}/basic_auth.py`),
path.normalize(`${this.serverless.config.servicePath}/basic_auth.py`)
);
} else {
throw error;
}
}
}

@@ -50,0 +65,0 @@

10

package.json
{
"name": "serverless-basic-authentication",
"version": "0.13.0",
"version": "0.14.0",
"devDependencies": {
"eslint": "^5.15.1",
"eslint-config-airbnb-base": "^13.1.0",
"eslint-plugin-import": "^2.14.0",
"jest": "^24.1.0"
"eslint": "^5.16.0",
"eslint-config-airbnb-base": "^13.2.0",
"eslint-plugin-import": "^2.18.0",
"jest": "^24.8.0"
},

@@ -10,0 +10,0 @@ "license": "MIT",

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