{"id":15579372,"url":"https://github.com/mrt1m/self-signed-certificate","last_synced_at":"2026-01-06T23:52:43.784Z","repository":{"id":248415510,"uuid":"729145550","full_name":"mrt1m/self-signed-certificate","owner":"mrt1m","description":"Example of creating a self-signed certificate for the server and clients","archived":false,"fork":false,"pushed_at":"2024-07-14T16:41:56.000Z","size":503,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-03T21:53:29.549Z","etag":null,"topics":["certificates","certificates-generator","client-cert-auth","client-certificates","openssl","openssl-tools","oscp-tools","ssl-cert","ssl-certificate-chain","ssl-certificates","trust-chain"],"latest_commit_sha":null,"homepage":"","language":"Makefile","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/mrt1m.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-08T14:21:21.000Z","updated_at":"2024-07-14T17:43:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"55878639-0f22-47c9-90af-a25fe694c449","html_url":"https://github.com/mrt1m/self-signed-certificate","commit_stats":{"total_commits":2,"total_committers":2,"mean_commits":1.0,"dds":0.5,"last_synced_commit":"3eca778716a650f2797bb18efcf47de2aa13eb26"},"previous_names":["mrt1m/self-signed-certificate"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrt1m%2Fself-signed-certificate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrt1m%2Fself-signed-certificate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrt1m%2Fself-signed-certificate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrt1m%2Fself-signed-certificate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mrt1m","download_url":"https://codeload.github.com/mrt1m/self-signed-certificate/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246156416,"owners_count":20732397,"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","certificates-generator","client-cert-auth","client-certificates","openssl","openssl-tools","oscp-tools","ssl-cert","ssl-certificate-chain","ssl-certificates","trust-chain"],"created_at":"2024-10-02T19:14:42.107Z","updated_at":"2026-01-06T23:52:43.725Z","avatar_url":"https://github.com/mrt1m.png","language":"Makefile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Example of a self-signed certificate\nIn this repository, I suggest looking at options for working with self-signed certificates. \nIf you find any errors or want to suggest an improvement, please, [make an issue](https://github.com/mrt1m/self-signed-certificate/issues) in a current repository\n\n## Requirements\n\n- Docker version 25.0.5\n\n## Quick guide\n\n0) Copy env and build openssl image\n    ```sh\n    cp .env.example .env\n    make openssl-build-image\n    ```\n   \n1) Create root certificate chain, server certificate, user certificates and configuration for nginx\n    ```sh\n    make step-create_all_certs-and-nginx_configs step-run_nginx\n    ```\n   ![screenshot of the result of creating a certificate chain](./docs/img/step-1.png)\n\n2) Run tests to check HTTPS and connections with the client certificate\n    ```sh\n    make step-run_tests\n    ```\n   ![screenshot of the result of tests](./docs/img/step-2.png)\n\n3) Check links in browser\n-  https://localhost/\n-  https://localhost/protection-magic/  \n   ![screenshot of the result of check links in browser](./docs/img/step-3.png)\n\n4) Import intermediate CA\n    \u003cdetails\u003e\n      \u003csummary\u003emacOS\u003c/summary\u003e\n    \n      ```sh\n      make import-macos-ca CA_NAME=intermediate.level_2.root.ca\n      ```\n    \u003c/details\u003e\n\n5) Check links in browser\n-  https://localhost/  \n   ![screenshot of the result of check index page in browser](./docs/img/step-5_1.png)\n-  https://localhost/protection-magic/  \n   ![screenshot of the result of check protection page in browser](./docs/img/step-5_2.png)\n\n6) Import client certificates\n\n    \u003cdetails\u003e\n      \u003csummary\u003emacOS\u003c/summary\u003e\n    \n      ```sh\n      make import-macos-client CA_NAME=intermediate.level_2.root.ca CLIENT_EMAIL=user_1@lol.kek\n      make import-macos-client CA_NAME=intermediate.level_2.root.ca CLIENT_EMAIL=user_2@lol.kek\n      ```\n    \u003c/details\u003e\n\n7) Re-enter the OS profile so that the system selects user certificates\n\n8) Run nginx\n    ```sh\n    make step-run_nginx\n    ```\n\n9) Check links in browser incognito mode\n\n\u003e [!IMPORTANT]\n\u003e Remember, if you want to change the user certificate, you need to restart the browser\n\n![screenshot of selecting a user certificate](./docs/img/step-9.png)\n\n- Don't select a user\n  -  https://localhost/  \n     ![screenshot of the result of check index page in browser](./docs/img/step-5_1.png)\n  -  https://localhost/protection-magic/  \n     ![screenshot of the result of check protection page in browser](./docs/img/step-5_2.png)\n- Select user_1 - this user's certificate has been revoked, so any page will return a 400 Bad Request\n   -  https://localhost/\n   -  https://localhost/protection-magic/  \n      ![screenshot of the result in browser](./docs/img/step-9_1.png)\n- Select user_2 - this user's certificate is active\n   -  https://localhost/  \n      ![screenshot of the result of check index page in browser](./docs/img/step-5_1.png)\n   -  https://localhost/protection-magic/  \n      ![screenshot of the result of check protection page in browser](./docs/img/step-9_2.png)\n\n10) Now in the OS settings we will see the following certificates\n    \u003cdetails\u003e\n      \u003csummary\u003emacOS\u003c/summary\u003e\n\n      1) open keychain  \n         ![screenshot of keychain icon](./docs/img/step-10_1.png)\n      2) certificates  \n         ![screenshot of certificates](./docs/img/step-10_2.png)\n         ![screenshot of ca certificate](./docs/img/step-10_3.png)\n         ![screenshot of clients certificates](./docs/img/step-10_4.png)\n      3) keychains  \n         ![screenshot of keychains](./docs/img/step-10_5.png)\n   \u003c/details\u003e\n\n---\n\n## Task lists\n\n- [ ] Add import commands for Windows and Linux\n- [ ] Add documentation\n- [ ] Add openssl OCSP example\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrt1m%2Fself-signed-certificate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmrt1m%2Fself-signed-certificate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrt1m%2Fself-signed-certificate/lists"}