WireGuard Archive on lore.kernel.org
 help / Atom feed
* Private and public keys generation
@ 2018-10-06 11:27 Evgeniy Ivanov
  2018-10-07  2:46 ` StarBrilliant
  2018-10-07  4:40 ` Aaron Jones
  0 siblings, 2 replies; 3+ messages in thread
From: Evgeniy Ivanov @ 2018-10-06 11:27 UTC (permalink / raw)
  To: wireguard

Hi everybody,

I’m able to generate the private keys pretty straightforward with any tool I like (eg: dd if=/dev/urandom bs=32 count=1 2>/dev/null | base64)

But now, I’m more curious about generating the public keys without using wg pubkey directly. Any thoughts?

Thanks!

-- 
Best Regards,
Evgeniy Ivanov

_______________________________________________
WireGuard mailing list
WireGuard@lists.zx2c4.com
https://lists.zx2c4.com/mailman/listinfo/wireguard

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Private and public keys generation
  2018-10-06 11:27 Private and public keys generation Evgeniy Ivanov
@ 2018-10-07  2:46 ` StarBrilliant
  2018-10-07  4:40 ` Aaron Jones
  1 sibling, 0 replies; 3+ messages in thread
From: StarBrilliant @ 2018-10-07  2:46 UTC (permalink / raw)
  To: wireguard

On Sun, Oct 7, 2018 at 9:13 AM Evgeniy Ivanov <e601809@gmail.com> wrote:
>
> Hi everybody,
>
> I’m able to generate the private keys pretty straightforward with any tool I like (eg: dd if=/dev/urandom bs=32 count=1 2>/dev/null | base64)
>
> But now, I’m more curious about generating the public keys without using wg pubkey directly. Any thoughts?
>
> Thanks!
>
> --
> Best Regards,
> Evgeniy Ivanov


Hi Evgeniy,

Try this Python code:
https://github.com/m13253/VxWireguard-Generator/blob/1859e1ed199b067764bb29b7b5cd332037f5a665/vwgen/common.py#L236

See the function "genkey" and "pubkey".

Best regards,
StarBrilliant
_______________________________________________
WireGuard mailing list
WireGuard@lists.zx2c4.com
https://lists.zx2c4.com/mailman/listinfo/wireguard

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Private and public keys generation
  2018-10-06 11:27 Private and public keys generation Evgeniy Ivanov
  2018-10-07  2:46 ` StarBrilliant
@ 2018-10-07  4:40 ` Aaron Jones
  1 sibling, 0 replies; 3+ messages in thread
From: Aaron Jones @ 2018-10-07  4:40 UTC (permalink / raw)
  To: Evgeniy Ivanov; +Cc: WireGuard mailing list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

On 06/10/18 11:27, Evgeniy Ivanov wrote:
> Hi everybody,
> 
> I’m able to generate the private keys pretty straightforward with
> any tool I like (eg: dd if=/dev/urandom bs=32 count=1 2>/dev/null |
> base64)

This is not sufficient, as documented on https://cr.yp.to/ecdh.html
("Computing secret keys"). Please use wg(8) or any other library or
application that supports Curve25519.

-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/

iQIzBAEBCgAdFiEEYKVBwe43zZh/jkxPivBzdIirMBIFAlu5jicACgkQivBzdIir
MBIMuA/7BjeS4tKQP7HnAFDLF5h5xt+dgYi/FyVBC2UbOIq24IbRPIDI/y2X9uQS
sa/Zs6bx2QvjI3HC7py6Q40XEm7M5QbsOo8uxQYsEJRGWnG0hsDsG2iZ7Rjz9iIz
rJ8w/gxbEtFmCsb2z7fZmoVlMLtdYSQG3HDyKPXsZsfccUGaK+Q0RMgObtLzg11Z
P0mryXiqonqUUjAC2fs4s9KGrT0ZLabdEzJoUwlv0+tGd94W5i3AJbWR0D+E8V7z
tkVWalYZvHdaGf8j0td5QHfbEdCjfSrTro+iWdZ/L0+sMQZrPM0MyOe5ZMNKlBXB
foWV4eXycqjcrgoI+hvLSr8ac/rfrd5dlK0cfl9xKmoG1rOqAtVpTJ1qDQYyYbuv
3iLNYAXjAzLTpknt2ZwGQsb5nxH1AwJ1oGMCcY3NDYfF2+u2HXka1vhPdTpySbXh
NwYQ2yLjG2R1wVdtb/z7otVtq4O3Z6yMj6GJfLimnEwHjDZOjSOn7w2RuV3CsI/C
zdVU6b4FTp+s3RAOFuTNaGlQ2ZHHejQFX5YvgFKs/hfxg+2zf114zoNocKQl1tZ0
oaxNERD5y8N97ySXc87/d59zn9cc6R476igecaAyPRVCmH2RbszAEqqr+RIu69yq
nK8mbL5Cuevkly+vOdjWrzXuad2/u4Jtxr8Qv7KppOExx5BjQ+g=
=HQ0D
-----END PGP SIGNATURE-----
_______________________________________________
WireGuard mailing list
WireGuard@lists.zx2c4.com
https://lists.zx2c4.com/mailman/listinfo/wireguard

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-06 11:27 Private and public keys generation Evgeniy Ivanov
2018-10-07  2:46 ` StarBrilliant
2018-10-07  4:40 ` Aaron Jones

WireGuard Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/wireguard/0 wireguard/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 wireguard wireguard/ https://lore.kernel.org/wireguard \
		wireguard@lists.zx2c4.com zx2c4-wireguard@archiver.kernel.org
	public-inbox-index wireguard


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/com.zx2c4.lists.wireguard


AGPL code for this site: git clone https://public-inbox.org/ public-inbox