Skip to content

Commit

Permalink
Flatten the directory structure of rules (#230)
Browse files Browse the repository at this point in the history
Now putting all stdlib rules in one directory rather than one per
module. This aligns well with third-party libraries.

Signed-off-by: Eric Brown <eric.brown@securesauce.dev>
  • Loading branch information
ericwb committed Jan 26, 2024
1 parent 8b7e94f commit 103403b
Show file tree
Hide file tree
Showing 58 changed files with 45 additions and 45 deletions.
Empty file.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
File renamed without changes.
Empty file.
Empty file.
Empty file.
Empty file.
File renamed without changes.
Empty file.
Empty file.
Empty file.
Empty file.
File renamed without changes.
Empty file.
Empty file.
Empty file.
File renamed without changes.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
90 changes: 45 additions & 45 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ precli.parsers =
python = precli.parsers.python:Python

precli.rules.go =
# precli/rules/go/stdlib/crypto/weak_cipher.py
GO001 = precli.rules.go.stdlib.crypto.weak_cipher:WeakCipher
# precli/rules/go/stdlib/crypto_weak_cipher.py
GO001 = precli.rules.go.stdlib.crypto_weak_cipher:WeakCipher

# precli/rules/go/stdlib/crypto/weak_hash.py
GO002 = precli.rules.go.stdlib.crypto.weak_hash:WeakHash
# precli/rules/go/stdlib/crypto_weak_hash.py
GO002 = precli.rules.go.stdlib.crypto_weak_hash:WeakHash

# precli/rules/go/stdlib/crypto/weak_key.py
GO003 = precli.rules.go.stdlib.crypto.weak_key:WeakKey
# precli/rules/go/stdlib/crypto_weak_key.py
GO003 = precli.rules.go.stdlib.crypto_weak_key:WeakKey

# precli/rules/go/golang_org_x_crypto/ssh_insecure_ignore_hostkey.py
GO501 = precli.rules.go.golang_org_x_crypto.ssh_insecure_ignore_hostkey:SshInsecureIgnoreHostKey
Expand All @@ -52,65 +52,65 @@ precli.rules.go =
GO503 = precli.rules.go.golang_org_x_crypto.weak_hash:WeakHash

precli.rules.python =
# precli/rules/python/stdlib/assert/assert.py
PY001 = precli.rules.python.stdlib.assert.assert:Assert
# precli/rules/python/stdlib/assert.py
PY001 = precli.rules.python.stdlib.assert:Assert

# precli/rules/python/stdlib/crypt/crypt_weak_hash.py
PY002 = precli.rules.python.stdlib.crypt.crypt_weak_hash:CryptWeakHash
PY002 = precli.rules.python.stdlib.crypt_weak_hash:CryptWeakHash

# precli/rules/python/stdlib/ftplib/ftp_cleartext.py
PY003 = precli.rules.python.stdlib.ftplib.ftp_cleartext:FtpCleartext
# precli/rules/python/stdlib/ftplib_cleartext.py
PY003 = precli.rules.python.stdlib.ftplib_cleartext:FtpCleartext

# precli/rules/python/stdlib/hashlib/hashlib_weak_hash.py
PY004 = precli.rules.python.stdlib.hashlib.hashlib_weak_hash:HashlibWeakHash
# precli/rules/python/stdlib/hashlib_weak_hash.py
PY004 = precli.rules.python.stdlib.hashlib_weak_hash:HashlibWeakHash

# precli/rules/python/stdlib/hmac/hmac_timing_attack.py
PY005 = precli.rules.python.stdlib.hmac.hmac_timing_attack:HmacTimingAttack
# precli/rules/python/stdlib/hmac_timing_attack.py
PY005 = precli.rules.python.stdlib.hmac_timing_attack:HmacTimingAttack

# precli/rules/python/stdlib/hmac/hmac_weak_hash.py
PY006 = precli.rules.python.stdlib.hmac.hmac_weak_hash:HmacWeakHash
# precli/rules/python/stdlib/hmac_weak_hash.py
PY006 = precli.rules.python.stdlib.hmac_weak_hash:HmacWeakHash

# precli/rules/python/stdlib/imaplib/imap_cleartext.py
PY007 = precli.rules.python.stdlib.imaplib.imap_cleartext:ImapCleartext
# precli/rules/python/stdlib/imaplib_cleartext.py
PY007 = precli.rules.python.stdlib.imaplib_cleartext:ImapCleartext

# precli/rules/python/stdlib/json/json_load.py
PY008 = precli.rules.python.stdlib.json.json_load:JsonLoad
# precli/rules/python/stdlib/json_load.py
PY008 = precli.rules.python.stdlib.json_load:JsonLoad

# precli/rules/python/stdlib/logging/insecure_listen_config.py
PY009 = precli.rules.python.stdlib.logging.insecure_listen_config:InsecureListenConfig
# precli/rules/python/stdlib/logging_insecure_listen_config.py
PY009 = precli.rules.python.stdlib.logging_insecure_listen_config:InsecureListenConfig

# precli/rules/python/stdlib/marshal/marshal_load.py
PY010 = precli.rules.python.stdlib.marshal.marshal_load:MarshalLoad
# precli/rules/python/stdlib/marshal_load.py
PY010 = precli.rules.python.stdlib.marshal_load:MarshalLoad

# precli/rules/python/stdlib/nntplib/nntp_cleartext.py
PY011 = precli.rules.python.stdlib.nntplib.nntp_cleartext:NntpCleartext
# precli/rules/python/stdlib/nntplib_cleartext.py
PY011 = precli.rules.python.stdlib.nntplib_cleartext:NntpCleartext

# precli/rules/python/stdlib/pickle/pickle_load.py
PY012 = precli.rules.python.stdlib.pickle.pickle_load:PickleLoad
# precli/rules/python/stdlib/pickle_load.py
PY012 = precli.rules.python.stdlib.pickle_load:PickleLoad

# precli/rules/python/stdlib/poplib/pop_cleartext.py
PY013 = precli.rules.python.stdlib.poplib.pop_cleartext:PopCleartext
# precli/rules/python/stdlib/pop_cleartext.py
PY013 = precli.rules.python.stdlib.poplib_cleartext:PopCleartext

# precli/rules/python/stdlib/shelve/shelve_open.py
PY014 = precli.rules.python.stdlib.shelve.shelve_open:ShelveOpen
# precli/rules/python/stdlib/shelve_open.py
PY014 = precli.rules.python.stdlib.shelve_open:ShelveOpen

# precli/rules/python/stdlib/smtplib/smtp_cleartext.py
PY015 = precli.rules.python.stdlib.smtplib.smtp_cleartext:SmtpCleartext
# precli/rules/python/stdlib/smtplib_cleartext.py
PY015 = precli.rules.python.stdlib.smtplib_cleartext:SmtpCleartext

# precli/rules/python/stdlib/ssl/create_unverified_context.py
PY016 = precli.rules.python.stdlib.ssl.create_unverified_context:CreateUnverifiedContext
# precli/rules/python/stdlib/ssl_create_unverified_context.py
PY016 = precli.rules.python.stdlib.ssl_create_unverified_context:CreateUnverifiedContext

# precli/rules/python/stdlib/ssl/insecure_tls_version.py
PY017 = precli.rules.python.stdlib.ssl.insecure_tls_version:InsecureTlsVersion
# precli/rules/python/stdlib/ssl_insecure_tls_version.py
PY017 = precli.rules.python.stdlib.ssl_insecure_tls_version:InsecureTlsVersion

# precli/rules/python/stdlib/ssl/sslcontext_weak_key.py
PY018 = precli.rules.python.stdlib.ssl.sslcontext_weak_key:SslContextWeakKey
# precli/rules/python/stdlib/ssl_context_weak_key.py
PY018 = precli.rules.python.stdlib.ssl_context_weak_key:SslContextWeakKey

# precli/rules/python/stdlib/telnetlib/telnetlib_cleartext.py
PY019 = precli.rules.python.stdlib.telnetlib.telnetlib_cleartext:TelnetlibCleartext
# precli/rules/python/stdlib/telnetlib_cleartext.py
PY019 = precli.rules.python.stdlib.telnetlib_cleartext:TelnetlibCleartext

# precli/rules/python/stdlib/tempfile/mktemp_race_condition.py
PY020 = precli.rules.python.stdlib.tempfile.mktemp_race_condition:MktempRaceCondition
# precli/rules/python/stdlib/tempfile_mktemp_race_condition.py
PY020 = precli.rules.python.stdlib.tempfile_mktemp_race_condition:MktempRaceCondition

# precli/rules/python/aiohttp/no_certificate_verify.py
PY501 = precli.rules.python.aiohttp.no_certificate_verify:NoCertificateVerify
Expand Down

0 comments on commit 103403b

Please sign in to comment.