Scripts

Posted:

[ Categories: ]

[Complete List]


  • WordPress Security Scan: WPScan
    #!/bin/bash
    
    # To update database to the lastest version, run
    #
    # wpscan --update
    #
    # Scan installed plugins
    #
    # wpscan --url http(s)://your-domain.com --enumerate p
    #
    # Scan vulnerable plugins
    # 
    # wpscan --url http(s)://your-domain.com --enumerate vp
    # 
    # Scan installed themes
    # 
    # wpscan --url http(s)://your-domain.com --enumerate t
    # 
    # Scan vulnerable themes
    # 
    # wpscan --url http(s)://your-domain.com --enumerate vt
    # 
    # Scan user accounts:
    # 
    # wpscan --url http(s)://your-domain.com --enumerate u
    # 
    # Scan vulnerable timthumb files:
    # 
    # wpscan --url http(s)://your-domain.com --enumerate tt
    
    OUTPUT_FILE="/mnt/storage-vol1-1/reports/wpscan-$(date '+%Y.%m.%d').txt"
    
    wpscan --url https://keystreams.io -o "${OUTPUT_FILE}" --enumerate p --enumerate vp --enumerate t --enumerate vt --enumerate u --enumerate tt
  • inotify-monitor_system.py
    #!/usr/bin/env python3
    #
    # watch:
    #  ~/.password-store
    #  ~/.gnupg
    #
    
    from inotifyrecursive import INotify, flags
    
    inotify = INotify()
    
    mask = flags.CREATE | flags.DELETE | flags.MODIFY | flags.DELETE_SELF | flags.ACCESS
    
    inotify.add_watch_recursive("${HOME}/.password-store", mask)
    inotify.add_watch_recursive("${HOME}/.gnupg", mask)
    
    while True:
      for event in inotify.read():
        #print(event.name)
        print(event)
        print(flags.from_mask(event.mask))
        for flag in flags.from_mask(event.mask):
          print('    ' + str(flag))