• Earn real money by being active: Hello Guest, earn real money by simply being active on the forum — post quality content, get reactions, and help the community. Once you reach the minimum credit amount, you’ll be able to withdraw your balance directly. Learn how it works.

Source Code Embeds/Extracts encrypted string in .PNG - PowerShell

dEEpEst

☣☣ In The Depths ☣☣
Staff member
Administrator
Super Moderator
Hacker
Specter
Crawler
Shadow
Joined
Mar 29, 2018
Messages
13,859
Solutions
4
Reputation
27
Reaction score
45,545
Points
1,813
Credits
55,080
‎7 Years of Service‎
 
56%
Embed a string (AES-encrypted and Base64-encoded) into the last IDAT chunk of a PNG and later extract and decrypt it to recover the original text.

Embeds encrypted string in .PNG file​

Syntax
Code:
# A secret text to embed
$secret = "This is top secret data..."
# Call the function
Embed-EncryptedStringInPNG -CoverPNG "C:\temp\cover.png" -StringData $secret -Passphrase "S0meStr0ngPass!" -OutputPNG "C:\temp\steg.png"

Script


Extracts encrypted string from .PNG file​


Syntax
Code:
$decryptedText = Extract-EncryptedStringFromPNG -StegoPNG "steg.png" -Passphrase "S0meStr0ngPass!"

Script
 
Back
Top