Reorganization of all modules.

This commit is contained in:
Cédric Bonhomme 2016-05-19 21:32:15 +02:00
parent e0bed8ba52
commit 872a5546fc
No known key found for this signature in database
GPG key ID: A1CB94DE57B7A70D
23 changed files with 77 additions and 43 deletions

View file

@ -25,7 +25,7 @@ __date__ = "$Date: 2016/03/18 $"
__license__ = "GPLv3"
try:
from stegano import slsb
from stegano import lsb
except:
print("Install Stegano: sudo pip install Stegano")
@ -68,7 +68,7 @@ if options.hide:
elif options.secret_message == "" and options.secret_file != "":
secret = tools.binary2base64(options.secret_file)
img_encoded = slsb.hide(options.input_image_file, secret)
img_encoded = lsb.hide(options.input_image_file, secret)
try:
img_encoded.save(options.output_image_file)
except Exception as e:
@ -76,7 +76,7 @@ if options.hide:
print(e)
elif options.reveal:
secret = slsb.reveal(options.input_image_file)
secret = lsb.reveal(options.input_image_file)
if options.secret_binary != "":
data = tools.base642binary(secret)
with open(options.secret_binary, "w") as f:

View file

@ -25,7 +25,7 @@ __date__ = "$Date: 2016/03/18 $"
__license__ = "GPLv3"
try:
from stegano import slsbset
from stegano import lsbset
except:
print("Install stegano: sudo pip install Stegano")
@ -74,7 +74,7 @@ if options.hide:
elif options.secret_message == "" and options.secret_file != "":
secret = tools.binary2base64(options.secret_file)
img_encoded = slsbset.hide(options.input_image_file, secret, options.generator_function)
img_encoded = lsbset.hide(options.input_image_file, secret, options.generator_function)
try:
img_encoded.save(options.output_image_file)
except Exception as e:
@ -83,7 +83,7 @@ if options.hide:
elif options.reveal:
try:
secret = slsbset.reveal(options.input_image_file, options.generator_function)
secret = lsbset.reveal(options.input_image_file, options.generator_function)
except IndexError:
print("Impossible to detect message.")
exit(0)