Skip to content
Projects

guofei9987/text_blind_watermark

View on GitHub

guofei9987/text_blind_watermark has 1,965 GitHub stars and 189 forks. GitHot measured 0 stars in 24 hours. Last checked 2026-11-07 00:53 UTC. Last push 2025-09-06.

How these counts are measured

文本盲水印:把信息隐匿到文本中,put invisible blind watermark into a text.

What you can do

  • Invisible watermark embedding in plain text
  • No visible difference in appearance
  • Verified in platforms: macOS, Windows, Linux, WeChat, DingTalk, Zhihu, Chrome, etc

Measured star growth

in 24h
0
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

README.md

Original

text_blind_watermark

Embed an invisible message (blind watermark) into text, without altering its readability or appearance.

PyPI Build Status codecov License Python Platform stars fork Downloads Featured|HelloGitHub

✨ Features

  • Invisible watermark embedding in plain text
  • No visible difference in appearance
  • Verified in platforms: macOS, Windows, Linux, WeChat, DingTalk, Zhihu, Chrome, etc

📦 Installation

pip install text_blind_watermark

🛠 Usage

Embed a watermark into text

from text_blind_watermark import TextBlindWatermark

password = b"p@ssw0rd"
watermark = b"This is watermark"
original_text_file = 'files/file_txt.txt'
file_with_watermark = 'files/file_txt_with_watermark.txt'

with open(original_text_file, 'r') as f:
    text = f.read()

twm = TextBlindWatermark(pwd=password)

# embed watermark into the text
text_with_wm = twm.add_wm_rnd(text=text, wm=watermark)

# write into a new file
with open(file_with_watermark, 'w') as f:
    f.write(text_with_wm)

Extract the watermark

from text_blind_watermark import TextBlindWatermark

password = b"p@ssw0rd"
file_with_watermark = 'files/file_txt_with_watermark.txt'

with open(file_with_watermark, 'r') as f:
    text_with_wm_new = f.read()

twm = TextBlindWatermark(pwd=password)
watermark_extract = twm.extract(text_with_wm_new)
print(watermark_extract)

Output: This is watermark

🔗 Related Project: HideInfo

算法 说明
migrate tank Show different images under different backgrounds
hide as image Store data as an image
hide in image Hide data inside an image
image seed Merge image and file together
EXIF Embed data in image EXIF metadata
hide as music Store data as audio
hide in music Hide data inside audio
hide as text Store data as plain text
hide in text Hide data within readable text

Explore related projects