Commit Graph

11 Commits

Author SHA1 Message Date
ginuerzh ffa7ceaed7 feat(tls): persist auto-generated CA certificate to $HOME/.gost/
Previously BuildDefaultTLSConfig generated a new random self-signed
certificate in memory on every run, making it impossible for users to
extract and trust the certificate in their system trust store.

Now when no explicit cert files are configured, GOST:
1. First checks cert.pem / key.pem in CWD (backward compatible)
2. Then checks auto-ca-cert.pem / auto-ca-key.pem under $HOME/.gost/
3. If none found, generates a new ECDSA P-256 CA certificate, persists
   it to $HOME/.gost/, and uses it

The persisted cert has IsCA=true so tools recognize it as a root CA.
Falls back to in-memory-only when disk writes fail.

Closes go-gost/gost#876
2026-06-23 20:29:57 +08:00
ginuerzh effba3b690 docs(parsing): add package and symbol doc comments
Add godoc comments for all 62 exported symbols across 20 files in
config/parsing/: 23 MDKey constants, 35 Parse*/List/Default* functions,
3 TLS helpers, 1 Args struct with 7 fields, and the package doc.
2026-05-24 13:58:37 +08:00
ginuerzh 489a762811 service graceful shutdown 2025-01-08 23:12:06 +08:00
ginuerzh ea585fc25d add reload and plugin support for hop 2023-09-28 21:04:15 +08:00
ginuerzh 18fa84b51f load default CA from ca.pem 2023-03-21 18:28:05 +08:00
ginuerzh a39800270b load default CA from ca.pem 2023-03-21 18:11:06 +08:00
ginuerzh 3b21b41ab3 add new metadata for dtls 2022-12-17 22:40:45 +08:00
ginuerzh cf20abf656 add hop 2022-09-22 18:45:15 +08:00
ginuerzh d7b56871a9 customize random-generated certificate information 2022-07-27 16:58:49 +08:00
ginuerzh 5f3e4177a1 improve file and redis loader 2022-04-21 23:24:52 +08:00
ginuerzh a3346ad246 add pkgs from core 2022-04-04 12:44:35 +08:00