Lines Matching defs:public
398 wg_peer_create(struct wg_softc *sc, uint8_t public[WG_KEY_SIZE])
414 noise_remote_init(&peer->p_remote, public, &sc->sc_local);
415 cookie_maker_init(&peer->p_cookie, public);
451 idx = SipHash24(&sc->sc_secret, public, WG_KEY_SIZE);
465 wg_peer_lookup(struct wg_softc *sc, const uint8_t public[WG_KEY_SIZE])
471 idx = SipHash24(&sc->sc_secret, public, WG_KEY_SIZE);
477 if (timingsafe_bcmp(peer_key, public, WG_KEY_SIZE) == 0)
1997 wg_remote_get(void *_sc, uint8_t public[NOISE_PUBLIC_KEY_LEN])
2001 if ((peer = wg_peer_lookup(sc, public)) == NULL)
2306 uint8_t public[WG_KEY_SIZE], private[WG_KEY_SIZE];
2326 if (curve25519_generate_public(public, iface_o.i_private)) {
2327 if ((peer = wg_peer_lookup(sc, public)) != NULL)
2339 has_identity == 0 ? public : NULL);
2370 /* Peer must have public key */
2382 /* Get local public and check that peer key doesn't match */
2383 if (noise_local_keys(&sc->sc_local, public, NULL) == 0 &&
2384 bcmp(public, peer_o.p_public, WG_KEY_SIZE) == 0)
2451 explicit_bzero(public, sizeof(public));