flutter_steganography

flutter_steganography is a simple package for fully transparent hiding any string within an image. This technique is known as LSB (Least Significant Bit) steganography

Getting Started

This project is a starting point for a Dart package, a library module containing code that can be shared easily across multiple Flutter or Dart projects.

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

Usage

How to encode message into an image?

  • Create an EncodeRequest
import 'dart:io';
...

File file = File(...);
// the key is use to encrypt your message with AES256 algorithm
EncodeRequest request = EncodeRequest(file.readAsBytesSync(), "your_message", key: "your_key");
  • Encode
// for async
Uint8List response = await encodeMessageIntoImageAsync(request);

//or for sync
Uint8List response = encodeMessageIntoImage(request);

  • Display encoded image
import 'package:flutter/material.dart';
...

Image.memory(response);

How to decode message from an image?

  • Create a DecodeRequest
import 'dart:io';
...

File file = File(...);
// the key is use to decrypt your encrypted message with AES256 algorithm
DecodeRequest request = DecodeRequest(file.readAsBytesSync(), key: "your_key");
  • Decode
// for async
String response = await decodeMessageFromImageAsync(request);

//or for sync
Uint8List response = decodeMessageFromImage(request);
  • Display message
import 'package:flutter/material.dart';
...

Text(response);

References

Libraries

base_request
decode_request
decoder
encode_request
encoder
flutter_steganography
pad_key
requests