Giter Club home page Giter Club logo

cert_tree's People

Contributors

jkolezyn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cert_tree's Issues

Certificate info when there is a OU instead a CN

Match of a certificate with a OU instead of CN does not recover info. This occurs with the certificate downloable in https://www.sede.fnmt.gob.es/documents/10445900/10526749/AC_FNMT_Usuarios.cer
Changing regexp in line 77 recovers this info. There is some alternatives.
match = re.match("^\s*(\w*): .(?:CN(?!OU)|OU) ?= ?(.)$", line)
# match = re.match("^\s*(\w*): .(?:CN(?!OU)|OU(?!CN)) ?= ?(.)$", line)
# match = re.match("^\s*(\w*): .(?:CN|OU) ?= ?(.)$", line)
When there is not this certificate info, the option -r can inappropriately remove the certificate.
Best Regards

SyntaxError: invalid syntax

Hi

./cert_tree.py -p /etc/ssl/certs/ca-certificates.crt
  File "./cert_tree.py", line 158
    postfix = f'[{root.position}]' if position and not root.missing else ''
                                 ^
SyntaxError: invalid syntax

Windows 10 and Powershell

PS XXXXX> openssl x509 -noout -issuer -dates -in .\ca.crt
issuer=C = BE, O = GlobalSign nv-sa, CN = GlobalSign RSA OV SSL CA 2018
notBefore=Feb 23 15:16:20 2023 GMT
notAfter=Mar 26 15:16:19 2024 GMT

PS XXXXX> python3.11.exe .\cert_tree.py -pe .\ca.crt
━ GlobalSign [3]
┗━ GlobalSign RSA OV SSL CA 2018 [2]
┗━ *.XXX.de [1]

Although the CMD tool shows an output under Windows, no info about the certificate duration is displayed by the Pyton script.

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xed in position 3566: invalid continuation byte

[/share/homes/admin] # python
Python 3.10.4 (main, Apr 13 2022, 08:47:51) [GCC 8.4.0] on linux

[/share/homes/admin] # python cert_tree.py -p /share/CACHEDEV1_DATA/.qpkg/container-station/etc/ssl/certs/ca-certificates.crt
Traceback (most recent call last):
File "/share/CACHEDEV1_DATA/homes/admin/cert_tree.py", line 210, in
main()
File "/share/CACHEDEV1_DATA/homes/admin/cert_tree.py", line 203, in main
certs = create_certs(certs)
File "/share/CACHEDEV1_DATA/homes/admin/cert_tree.py", line 62, in create_certs
certs.append(create_cert(content, position))
File "/share/CACHEDEV1_DATA/homes/admin/cert_tree.py", line 73, in create_cert
for line in out.decode().split('\n'):
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xed in position 3566: invalid continuation byte

Running on QNAP NAS with OS 5.x

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.