Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Make OK for Public - Hide usernames, passwords, hostnames, IPs, (what else), in preparation of a gist or other sharing? [Maturity: New]
Ruby Perl Shell
branch: master

Version bump

latest commit 65a68ac6c1
@rking rking authored committed



Make OK for Public. A simplistic pre-filter (not (yet|ever) a substitute for manual examination).


mop < /var/log/nginx/error_log > cleaned_file
vim cleaned_file
# ☝ check for anything it might've missed
jist -co cleaned_file
# ☝ upload, copy its URL to clipboard, open in browser


This thing is really in its beginning phases. It currently:

  • Deletes too much

  • Leaves too much

However, all Issues will be addressed. Just file 'em at:

Currently Works With

  • Passwords

    • "password: secr3t""password: hiddenpass"

    • "password: secr3t""password: hiddenpass"

    • "password:\n\tsecr3t""password:\n\thiddenpass"

    • "password: 'secr3t'""password: hiddenpass"

    • "password:secr3t""password:hiddenpass"

    • "passwd:secr3t""passwd:hiddenpass"

    • "passwd: secr3t""passwd: hiddenpass"

    • "password=secr3t""password=hiddenpass"

    • "passwd=secr3t""passwd=hiddenpass"

    • "password=\"secr3t\"""password=hiddenpass"

    • "buzbuz password: secr3t bizbiz""buzbuz password: hiddenpass bizbiz"

    • "buzbuz password: secr3t bizbiz another password: secr4t bazbaz""buzbuz password: hiddenpass bizbiz another password: hiddenpass bazbaz"

    • "USER: user55 PASS: secr3t""USER: hiddenuser PASS: hiddenpass"

    • "U/N: user55 P/W: secr3t""U/N: hiddenuser P/W: hiddenpass"

    • "U: user55 P: secr3t""U: hiddenuser P: hiddenpass"

    • "U=user55 P=secr3t""U=hiddenuser P=hiddenpass"

    • "u=user55 p=secr3t""u=hiddenuser p=hiddenpass"

    • "u: user55 p: secr3t""u: hiddenuser p: hiddenpass"

    • "L=user55 P=secr3t""L=hiddenuser P=hiddenpass"

  • Users

    • "user: user55""user: hiddenuser"

    • "User=user55""User=hiddenuser"

    • "/Users/user55""hiddenuser"

    • "/home/user55""hiddenuser"

  • IPv4 Addresses

    • """XX.YY.ZZ.AA"

    • "asdf asdf""asdf XX.YY.ZZ.AA asdf"

    • """XX.YY.ZZ.AA:22"

    • """XX.YY.ZZ.AA"

    • "" unchanged

    • "" unchanged

  • IPv6 Addresses (probably many patterns TODO on this one)

    • "21:43:6f:1a:f6:f6""aa:bb:cc:dd:ee:ff"

  • Capistrano's `deploy.rb`

    • "host_name: 'shouldhide'""host_name: caphidden"

    • "host_name: \"shouldhide\"""host_name: caphidden"

    • ":host_name => 'shouldhide'"":host_name => caphidden"

    • ":host_name, 'shouldhide'"":host_name, caphidden"

    • ":port => 'shouldhide'"":port => caphidden"

    • "deploy_to, 'shouldhide'""deploy_to, caphidden"

    • "server 'shouldhide', …""server capserver …"

    • "set :application, \"shouldhide\"""set :application, caphidden"

    • "set :user, \"shouldhide\"""set :user, hiddenuser"

    • "server without comma" unchanged

    • "portage" unchanged

  • /etc/passwd having “fakeuser” and “fakeuser2”

    • "foo bar fakeuser baz""foo bar hiddenuser baz"

    • "~/fakeuser""~/hiddenuser"

    • "/home/fakeuser/.foo""hiddenuser"

    • "fakeuser2""hiddenuser"

    • "cron" unchanged

    • "root" unchanged

  • hostname being 'gargantatron'

    • "gargantatron""hiddenhost"

  • Git repos

  • SSH

    • "ssh://user55@secrethost/path/to/reponame.git/""ssh://hiddensshurl"


  • Add -j for ConradIrwin's jist gem (after an editor preview, of course)

  • Make distinct (similar to an uglifier's symbol replacement)

    • ⇒ hiddenhostname1

    • ⇒ hiddenhostname2

  • Learn more about IPv6 Addresses

  • Dorky ISP-given hostnames that show IP addresses

Something went wrong with that request. Please try again.