jkolezyn / cert_tree

Simple script to view a chain of x509 certificates stored in a single PEM file as a tree. It also enables viewing expiry dates and purging expired certificates. It uses openssl under the hood. It builds the tree looking only at Subject and Issuer fields. It does NOT validate the certificate chain.
31 stars 8 forks source link

SyntaxError: invalid syntax #1

Open zepelin16 opened 2 years ago

zepelin16 commented 2 years ago

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
jkolezyn commented 2 years ago

Thanks. What python version are you using?

I will look into this when I have some free time.

zepelin16 commented 2 years ago

Thanks. What python version are you using?

I will look into this when I have some free time.

Python 3.5.2 (default, Jan 26 2021, 13:30:48) [GCC 5.4.0 20160609] on linux

jkolezyn commented 2 years ago

Yes, so this is actually the answer. F-strings are available from Python 3.6.

I will try to change this not to use f-strings when I have more time.