npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

simplify-secops

v0.1.6

Published

Simplify Security & Operation Interface

Downloads

5

Readme

Security & Operation

NPM Downloads Package Version

This project aims to cover SecOps for AWS Lambda serverless first. To use this package, install it as a global comand line tool:

npm install -g simplify-secops

Define a function list in CSV format:

Region,Account,FunctionName,Version,LogRetention,KMS,SecureFunction,SecureLog
eu-west-1,123456789012,test-function-kms,,90,1,TRUE,FALSE

Command Line Support:

  • Verify deployed functions against your list of definitions

    • simplify-secops -p simplify-eu verify -i functions.csv --simple
  • Record a snapshot with current state of functions

    • simplify-secops -p simplify-eu snapshot -i functions.csv -o .snapshot
  • Verify deployed functions with a specified snapshot date

    • simplify-secops -p simplify-eu verify -i functions.csv -b 2020-06-21
  • Check deployed functions and functions' parameters

    • simplify-secops -p simplify-eu check -i functions.csv
  • Patch deployed functions with functions' parameters

    • simplify-secops -p simplify-eu patch -i functions.csv
  • Monitor deployed functions with standard simple view metrics

    eg: options for last 12 hours with sample in every 5 mins (5*60 = 300) seconds

    • simplify-secops -p simplify-eu metric -i functions.csv -t 300 -h 12

    eg: drawing the function data with index=1 and INVOCATIONS (1) as a timeseries chart

    • simplify-secops -p simplify-eu metric -i functions.csv -t 300 -h 12 --plot 1,1

      2.00 ┼╮ 1.95 ┤│ 1.90 ┤│ 1.85 ┤│ 1.80 ┤│ 1.75 ┤│ 1.70 ┤│ 1.65 ┤│ 1.60 ┤│ 1.55 ┤│ 1.50 ┤│ 1.45 ┤│ 1.40 ┤│ 1.35 ┤│ 1.30 ┤│ 1.25 ┤│ 1.20 ┤│ 1.15 ┤│ 1.10 ┤│ 1.05 ┤│ 1.00 ┤╰

    • 1- Invocations BLUE: 3 | 2- Errors RED: 0 | 3- Max Duration GREEN: 938.53 | 4- Max Concurrency YELLOW: 2 | 5- Throttles WHITE: 4

Example of (security) metrics:


| Index | Function | CodeSHA256 | Layers | LogRetention | EncryptionKey | SecureFunction | SecureLog | |-------|--------------------|-------------|--------|--------------|---------------|----------------|-------------| | 1 | test-function-foo | 9AD72= (OK) | 1 (OK) | 90 / 90 (OK) | KMS (OK) | YES (OK) | NO (OK) | | 2 | foo-secret-manager | f4Bfa= (OK) | 1 (OK) | 90 / 90 (OK) | Default (OK) | YES (PATCH) | YES (PATCH) | | 3 | foo-user-manager | bcBa1= (OK) | 1 (OK) | 90 / 90 (OK) | Default (OK) | NO (OK) | NO (OK) |

Example of (operation) metrics:


| Index | Function | Invocations | Errors | Duration | Concurrency | |-------|--------------------------|-------------|---------|-------------|-------------| | 1 | test-function-foo | 120 | 4 | 321.43 | 31 | | 2 | foo-secret-manager | 1 | 0 | 1161.00 | 1 | | 3 | foo-user-manager | 1 | 0 | 938.53 | 1 | | | Statistics in 12 hours | 122 | 4 | 1161.00 | 33 |