Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore certificate error #20

Closed
jx6f opened this issue Aug 14, 2018 · 2 comments
Closed

Ignore certificate error #20

jx6f opened this issue Aug 14, 2018 · 2 comments
Labels
bug Something isn't working Fixed Issue Fixed!

Comments

@jx6f
Copy link

jx6f commented Aug 14, 2018

Hello, @Tuhinshubhra. Thank you for sharing the CMSeeK!
I found that if a target http server uses self-signed certificate, CMSeeK couldn't scan.

informations:

  • Target: A self signed https server
  • Exact copy of error
    $python cmseek.py -u https://localhost:8443
    
    
     _____ _____ _____         _____
    |     |     |   __|___ ___|  |  | by @r3dhax0r
    |   --| | | |__   | -_| -_|    -|
    |_____|_|_|_|_____|___|___|__|__| Version 1.0.8
    
    
     [+]  CMS Detection And Deep Scan  [+] 
    
    
    [i] Scanning Site: https://localhost:8443/
    [x] Aborting CMSeek! Couldn't connect to site 
        Error: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate (_ssl.c:1045)>
    
    
    [i] Log saved in: /path/to/CMSeeK/Result/localhost:8443/cms.json
    
    
      _/\_  totsiens ~~ CMSeeK 
  • Your operating system
    $ cat /etc/issue
    Arch Linux \r (\l)
    
    $uname -r
    4.17.14-arch1-1-ARCH
    
    $python -V
    Python 3.7.0

Following patch works for me.

diff --git a/cmseek.py b/cmseek.py
index 9f9b260..4a3c694 100644
--- a/cmseek.py
+++ b/cmseek.py
@@ -48,6 +48,10 @@ elif args.random_agent is not None:
     cua = cmseek.randomua('random')
 else:
     cua = None
+
+import ssl
+ssl._create_default_https_context = ssl._create_unverified_context
+
 if args.url is not None:
     s = args.url
     target = cmseek.process_url(s)

Thanks!

@Tuhinshubhra Tuhinshubhra added the bug Something isn't working label Aug 14, 2018
@Tuhinshubhra Tuhinshubhra added the Fixed Issue Fixed! label Aug 14, 2018
@Tuhinshubhra
Copy link
Owner

Fixed, pleasse update your version of CMSeeK

@jx6f
Copy link
Author

jx6f commented Aug 14, 2018

I confirmed fix. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Fixed Issue Fixed!
Projects
None yet
Development

No branches or pull requests

2 participants