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

steganojs

v1.0.7

Published

Steganography package for PNG files. Can be used in web browser and backend code.

Downloads

24

Readme

SteganoJS

Description

This is a basic steganography library inspired by steganography, using the Lowest Significant Bit (LSB) algorithm.

This package uses the more lightweight pngjs for image parsing, nice ES6+ features, and a pure functional approach. It is designed for programmatic use.

There is currently only support for .png files.

Badges

Npm package version

Minimum node.js version

Npm package license

Npm package total downloads

Visuals

LSB Steganography

Installation

npm install steganojs

Usage

To conceal a message in an image:

// Import built-in module
import { readFileSync, writeFileSync } from 'fs';

// Import module function
import { conceal } from 'steganojs';

const imageBuffer = readFileSync('./path/to/image.png'); // buffer
const messageToConceal = 'keep it secret, keep it safe'; // string or buffer

// Encoding should be supplied if message is provided as a string in non-default encoding

const encodedFile = conceal(
  imageBuffer,
  messageToConceal,
  /*, optional Buffer Encoding
  , optional AES256 encryption password */
);

writeFileSync('./path/to/output.png', encodedFile);

To reveal a message hidden in an image:

// Import built-in module
import { readFileSync } from 'fs';

// Import module function
import { reveal } from 'steganojs';

const imageBuffer = readFileSync('./path/to/image.png'); // buffer

// Returns a string if encoding is provided, otherwise a buffer
const revealedMessage = reveal(
  imageBuffer,
  /*, optional Buffer Encoding
  , optional AES256 encryption password */
);

console.log(revealedMessage.toString());

Support

If you need help, please go to the project issue tracker.

Road map

Tests

  • Add Buffer tests
  • Add XML/TOML encoding tests
  • Add tests on dynamic generated PNG file and buffers
  • Add code coverage analysis

CI/CD Pipeline

  • Add automatic semantic version numbering for small updates

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

You can also document commands to lint the code or run tests.These steps help to ensure high code quality and reduce the likelihood that the changes inadvertently break something.

Authors and acknowledgment

This module is a Typescript refactoring of the initial steggy JavaScript module by Will Clark.

I want to thank C-J Kihl for his article on how to publish a TypeScript NPM package and webbureaucrat for his help with Continuously Deploying an NPM Package with GitLab CI/CD.

I want to thank Naereen for his document about README.md badges.

License

AGPL 3.0

Project status

Currently working on the project.