rebuild protobufs adding ECC_P256 to KeyType

This commit is contained in:
pacrob
2024-04-27 10:51:36 -06:00
committed by Paul Robinson
parent 827d16b106
commit c770a05d23
11 changed files with 80 additions and 91 deletions

View File

@ -2,20 +2,16 @@
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
import builtins
import google.protobuf.descriptor
import google.protobuf.message
import libp2p.crypto.pb.crypto_pb2
import sys
if sys.version_info >= (3, 8):
import typing as typing_extensions
else:
import typing_extensions
import typing
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
@typing_extensions.final
@typing.final
class Exchange(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
@ -30,7 +26,7 @@ class Exchange(google.protobuf.message.Message):
id: builtins.bytes | None = ...,
pubkey: libp2p.crypto.pb.crypto_pb2.PublicKey | None = ...,
) -> None: ...
def HasField(self, field_name: typing_extensions.Literal["id", b"id", "pubkey", b"pubkey"]) -> builtins.bool: ...
def ClearField(self, field_name: typing_extensions.Literal["id", b"id", "pubkey", b"pubkey"]) -> None: ...
def HasField(self, field_name: typing.Literal["id", b"id", "pubkey", b"pubkey"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["id", b"id", "pubkey", b"pubkey"]) -> None: ...
global___Exchange = Exchange

View File

@ -182,8 +182,7 @@ class InsecureTransport(BaseSecureTransport):
def make_exchange_message(pubkey: PublicKey) -> plaintext_pb2.Exchange:
pubkey_pb = crypto_pb2.PublicKey(
# type ignored - TODO add ECD_P256 to KeyType
key_type=pubkey.get_type().value, # type: ignore
key_type=pubkey.get_type().value,
data=pubkey.to_bytes(),
)
id_bytes = ID.from_pubkey(pubkey).to_bytes()

View File

@ -2,19 +2,15 @@
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
import builtins
import google.protobuf.descriptor
import google.protobuf.message
import sys
if sys.version_info >= (3, 8):
import typing as typing_extensions
else:
import typing_extensions
import typing
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
@typing_extensions.final
@typing.final
class NoiseHandshakePayload(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
@ -31,6 +27,6 @@ class NoiseHandshakePayload(google.protobuf.message.Message):
identity_sig: builtins.bytes = ...,
data: builtins.bytes = ...,
) -> None: ...
def ClearField(self, field_name: typing_extensions.Literal["data", b"data", "identity_key", b"identity_key", "identity_sig", b"identity_sig"]) -> None: ...
def ClearField(self, field_name: typing.Literal["data", b"data", "identity_key", b"identity_key", "identity_sig", b"identity_sig"]) -> None: ...
global___NoiseHandshakePayload = NoiseHandshakePayload

View File

@ -2,19 +2,15 @@
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
import builtins
import google.protobuf.descriptor
import google.protobuf.message
import sys
if sys.version_info >= (3, 8):
import typing as typing_extensions
else:
import typing_extensions
import typing
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
@typing_extensions.final
@typing.final
class Propose(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
@ -37,12 +33,12 @@ class Propose(google.protobuf.message.Message):
ciphers: builtins.str | None = ...,
hashes: builtins.str | None = ...,
) -> None: ...
def HasField(self, field_name: typing_extensions.Literal["ciphers", b"ciphers", "exchanges", b"exchanges", "hashes", b"hashes", "public_key", b"public_key", "rand", b"rand"]) -> builtins.bool: ...
def ClearField(self, field_name: typing_extensions.Literal["ciphers", b"ciphers", "exchanges", b"exchanges", "hashes", b"hashes", "public_key", b"public_key", "rand", b"rand"]) -> None: ...
def HasField(self, field_name: typing.Literal["ciphers", b"ciphers", "exchanges", b"exchanges", "hashes", b"hashes", "public_key", b"public_key", "rand", b"rand"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["ciphers", b"ciphers", "exchanges", b"exchanges", "hashes", b"hashes", "public_key", b"public_key", "rand", b"rand"]) -> None: ...
global___Propose = Propose
@typing_extensions.final
@typing.final
class Exchange(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
@ -56,7 +52,7 @@ class Exchange(google.protobuf.message.Message):
ephemeral_public_key: builtins.bytes | None = ...,
signature: builtins.bytes | None = ...,
) -> None: ...
def HasField(self, field_name: typing_extensions.Literal["ephemeral_public_key", b"ephemeral_public_key", "signature", b"signature"]) -> builtins.bool: ...
def ClearField(self, field_name: typing_extensions.Literal["ephemeral_public_key", b"ephemeral_public_key", "signature", b"signature"]) -> None: ...
def HasField(self, field_name: typing.Literal["ephemeral_public_key", b"ephemeral_public_key", "signature", b"signature"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["ephemeral_public_key", b"ephemeral_public_key", "signature", b"signature"]) -> None: ...
global___Exchange = Exchange