Skip to content

awg genconf command to generate random config parameters - #48

Open
vgrebenschikov wants to merge 1 commit into
amnezia-vpn:masterfrom
vgrebenschikov:feature/genconf
Open

awg genconf command to generate random config parameters #48
vgrebenschikov wants to merge 1 commit into
amnezia-vpn:masterfrom
vgrebenschikov:feature/genconf

Conversation

@vgrebenschikov

@vgrebenschikov vgrebenschikov commented May 21, 2026

Copy link
Copy Markdown

Generate a base AmneziaWG interface config with random PrivateKey,
ListenPort, junk packet settings, packet junk sizes, and magic headers.

Reuse the existing secure random implementation from genkey, avoid
overlapping magic header ranges, and skip UDP ports that are already bound.

Example of use:

$ awg genconf
[Interface]
ListenPort = 18354
PrivateKey = OMun4tlUqxsrkM0qr7BNDIXL5AcZiW0SYgWgU6C1T20=
Jc = 9
Jmin = 100
Jmax = 442
S1 = 434
S2 = 484
S3 = 271
S4 = 15
H1 = 4241571220-4241599444
H2 = 372628373-372667566
H3 = 2962273012-2962285084
H4 = 1423761423-1423772358

@vgrebenschikov vgrebenschikov changed the title Generate a base AmneziaWG interface config with random PrivateKey, awg genconf command to generate random config parameters May 21, 2026
Generate a base AmneziaWG interface config with random PrivateKey,
ListenPort, junk packet settings, packet junk sizes, and magic headers.

Reuse the existing secure random implementation from genkey, avoid
overlapping magic header ranges, and skip UDP ports that are already bound.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant