How to use the termcolor.termcolor.cprint function in termcolor

To help you get started, we’ve selected a few termcolor examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github DedSecInside / ViPER-CLI / modules / info_disclosure.py View on Github external
def get_dot_git(self, target):
        cprint("[*]Checking for .git folder", 'yellow')
        url = target
        target = "{0.scheme}://{0.netloc}/".format(urlsplit(url))
        req = requests.get(target+"/.git/")
        r = req.status_code
        if r == 200:
            cprint("Alert!", 'red')
            cprint(".git folder exposed publicly", 'red')
        else:
            print("NO .git folder found", 'blue')
github DedSecInside / ViPER-CLI / modules / info_disclosure.py View on Github external
def get_dot_git(self, target):
        cprint("[*]Checking for .git folder", 'yellow')
        url = target
        target = "{0.scheme}://{0.netloc}/".format(urlsplit(url))
        req = requests.get(target+"/.git/")
        r = req.status_code
        if r == 200:
            cprint("Alert!", 'red')
            cprint(".git folder exposed publicly", 'red')
        else:
            print("NO .git folder found", 'blue')
github DedSecInside / ViPER-CLI / modules / info_disclosure.py View on Github external
def get_robots_txt(self, target):
        cprint("[*]Checking for Robots.txt", 'yellow')
        url = target
        target = "{0.scheme}://{0.netloc}/".format(urlsplit(url))
        req = requests.get(target+"/robots.txt")
        r = req.text
        cprint(r, 'blue')
github DedSecInside / ViPER-CLI / modules / info_disclosure.py View on Github external
def get_dot_htaccess(self, target):
        cprint("[*]Checking for .htaccess", 'yellow')
        url = target
        target = "{0.scheme}://{0.netloc}/".format(urlsplit(url))
        req = requests.get(target+"/.htaccess")
        r = req.text
        statcode = req.status_code
        if statcode == 403:
            cprint("403 Forbidden", 'blue')
        elif statcode == 200:
            cprint("Alert!!", 'blue')
            cprint(".htaccess file found!", 'blue')
        else:
            cprint("Status code", 'blue')
            cprint(statcode, 'blue')
github DedSecInside / ViPER-CLI / modules / info_disclosure.py View on Github external
def get_dot_htaccess(self, target):
        cprint("[*]Checking for .htaccess", 'yellow')
        url = target
        target = "{0.scheme}://{0.netloc}/".format(urlsplit(url))
        req = requests.get(target+"/.htaccess")
        r = req.text
        statcode = req.status_code
        if statcode == 403:
            cprint("403 Forbidden", 'blue')
        elif statcode == 200:
            cprint("Alert!!", 'blue')
            cprint(".htaccess file found!", 'blue')
        else:
            cprint("Status code", 'blue')
            cprint(statcode, 'blue')
github DedSecInside / ViPER-CLI / Viper.py View on Github external
i.execute_all_func(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Testing HTTP Methods", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    hc = httpCommands()
    hc.execute_all_func(target)
    if args.injection or args.All:
        cprint("--------------------------------------------------------------", 'green')
        cprint("[+]      Checking for SQL Injection", 'yellow')
        cprint("--------------------------------------------------------------", 'green')
        sql = sqli()
        sql.execute_all_func(target)
    if args.xss or args.All:
        cprint("---------------------------------------------------------------", 'green')
        cprint("[+]      Checking for XSS Injection", 'yellow')
        cprint("--------------------------------------------------------------", 'green')
        x = xss()
        x.execute_all_func(target)
if __name__ == '__main__':
github DedSecInside / ViPER-CLI / Viper.py View on Github external
def main():
    parser = argparse.ArgumentParser(description="Web Recon Script")
    parser.add_argument('-u', '--url', type=str, help='URL', required=True)
    parser.add_argument('-A1', '--injection', help='Injection Attacks', action="store_true")
    parser.add_argument('-A3', '--xss', help='XSS', action="store_true")
    parser.add_argument('-a', '--All', help='All possible Attacks', action="store_true")
    args = parser.parse_args()
    target = args.url
    cprint('`````````````````````````````````````````````````````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('`````````                                  ```````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('```````````````````````````````````````````````````````', 'red')
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Getting the Headers", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    h = header()
    h.get_headers(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Extracting Cookies ", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    c = Cookie()
    c.execute_all_func(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]     Information Disclosure", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    i = info()
    i.execute_all_func(target)
    cprint("--------------------------------------------------------------", 'green')
github DedSecInside / ViPER-CLI / Viper.py View on Github external
def main():
    parser = argparse.ArgumentParser(description="Web Recon Script")
    parser.add_argument('-u', '--url', type=str, help='URL', required=True)
    parser.add_argument('-A1', '--injection', help='Injection Attacks', action="store_true")
    parser.add_argument('-A3', '--xss', help='XSS', action="store_true")
    parser.add_argument('-a', '--All', help='All possible Attacks', action="store_true")
    args = parser.parse_args()
    target = args.url
    cprint('`````````````````````````````````````````````````````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('`````````                                  ```````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('```````````````````````````````````````````````````````', 'red')
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Getting the Headers", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    h = header()
    h.get_headers(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Extracting Cookies ", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    c = Cookie()
    c.execute_all_func(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]     Information Disclosure", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
github DedSecInside / ViPER-CLI / Viper.py View on Github external
def main():
    parser = argparse.ArgumentParser(description="Web Recon Script")
    parser.add_argument('-u', '--url', type=str, help='URL', required=True)
    parser.add_argument('-A1', '--injection', help='Injection Attacks', action="store_true")
    parser.add_argument('-A3', '--xss', help='XSS', action="store_true")
    parser.add_argument('-a', '--All', help='All possible Attacks', action="store_true")
    args = parser.parse_args()
    target = args.url
    cprint('`````````````````````````````````````````````````````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('`````````                                  ```````', 'red')
    cprint('`````````                                     ```````', 'red')
    cprint('```````````````````````````````````````````````````````', 'red')
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Getting the Headers", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    h = header()
    h.get_headers(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]      Extracting Cookies ", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    c = Cookie()
    c.execute_all_func(target)
    cprint("--------------------------------------------------------------", 'green')
    cprint("[+]     Information Disclosure", 'yellow')
    cprint("--------------------------------------------------------------", 'green')
    i = info()