{"id":22843365,"url":"https://github.com/milahu/nssdb-py","last_synced_at":"2025-03-31T05:11:51.483Z","repository":{"id":210936377,"uuid":"727726535","full_name":"milahu/nssdb-py","owner":"milahu","description":"add a ca.crt certificate to $HOME/.pki/nssdb/cert9.db and $HOME/.pki/nssdb/key4.db in python","archived":false,"fork":false,"pushed_at":"2023-12-05T18:43:03.000Z","size":8,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-06T09:38:38.987Z","etag":null,"topics":["certificates","certutil","https","nss","nssdb","ssl","tls"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/milahu.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"license.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-05T13:01:29.000Z","updated_at":"2024-06-13T21:59:02.000Z","dependencies_parsed_at":null,"dependency_job_id":"b111cee3-7b11-433c-9bd3-d5247e65c4ad","html_url":"https://github.com/milahu/nssdb-py","commit_stats":null,"previous_names":["milahu/nssdb-py"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/milahu%2Fnssdb-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/milahu%2Fnssdb-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/milahu%2Fnssdb-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/milahu%2Fnssdb-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/milahu","download_url":"https://codeload.github.com/milahu/nssdb-py/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246418646,"owners_count":20773938,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["certificates","certutil","https","nss","nssdb","ssl","tls"],"created_at":"2024-12-13T02:14:30.107Z","updated_at":"2025-03-31T05:11:51.478Z","avatar_url":"https://github.com/milahu.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# nssdb-py\n\nadd a `ca.crt` certificate to `$HOME/.pki/nssdb/cert9.db` and `$HOME/.pki/nssdb/key4.db` in python\n\nimplement this part of certutil in python:\n\n```\ncertutil -d sql:$HOME/.pki/nssdb -A -t TC -n \"Some Authority\" -i ca.crt\n```\n\n## related\n\n- https://github.com/nss-dev/nss\n  - https://github.com/nss-dev/nss/blob/master/lib/softoken/sdb.c\n    - `sdb_init(cert, \"nssPublic\"`\n- https://www.dogtagpki.org/wiki/Support_NSSDB_in_Python_API\n  - draft\n- https://github.com/drGrove/mtls-cli/blob/main/src/mtls/mtls.py\n  - using `certutil`\n\n### parse SSL certificates in python\n\naka: X.509 certificates\n\n- https://stackoverflow.com/questions/16899247/how-can-i-decode-a-ssl-certificate-using-python\n  - https://stackoverflow.com/a/68060835/10440128\n    - `import ssl; ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT); ctx.load_verify_locations(\"ca.crt\"); cert = ctx.get_ca_certs()`\n  - https://cryptography.io/en/latest/x509/reference/#loading-certificates\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmilahu%2Fnssdb-py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmilahu%2Fnssdb-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmilahu%2Fnssdb-py/lists"}