0.2.0 • Published 8 years ago

steganogre v0.2.0

Weekly downloads
2
License
GPL-2.0
Repository
github
Last release
8 years ago

mascot

SteganOgre.js

Front-end library for storing and retrieving messages from image data.

encode

var steganogre = require('steganogre')
var encoded = steganogre.encodeString('your message')
var img = new Image()
var a = document.createElement('a')

img.src = encoded.dataURL // set generated imageData to img element src to preview it
a.href = encoded.downloadHref() // set download link for generated image with encoded data

decode

var steganogre = require('steganogre')
var decoding = steganogre.decodeToString('http://imgur.com/URL_TO_YOUR_IMAGE_WITH_ENCODED_MESSAGE')

decoding.then(function(msg) {
  console.log(msg)
})

Additional notes

Encryption

Data is stored as is into RGB channels of image data. If you want encrypted/protected content you need to handle that part yourself and pass cyphertext to steganogre.encodeString method.

CORS

If you are trying to retrieve image data with steganogre.decodeString from different URI scheme and it doesn't work, it's probably because source server is not set up with appropriate CORS headers(check out console error output). 3rd party services that do set appropriate CORS headers are imgur and dropbox

0.2.0

8 years ago

0.1.9

8 years ago

0.1.8

8 years ago

0.1.7

8 years ago

0.1.6

8 years ago

0.1.4

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago

0.0.3

8 years ago