Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public EnclavePublicKey(byte[] payload)

internal class EnclaveDiffieHellmanInfo
{
public int Size => sizeof(int) + sizeof(int) + PublicKey?.Length ?? 0 + PublicKeySignature?.Length ?? 0;
public int Size => sizeof(int) + sizeof(int) + (PublicKey?.Length ?? 0) + (PublicKeySignature?.Length ?? 0);

public byte[] PublicKey { get; private set; }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,7 @@ public AzureAttestationInfo(byte[] attestationInfo)
EnclaveDHInfo = new EnclaveDiffieHellmanInfo(attestationInfo, offset);
offset += EnclaveDHInfo.Size;

// TODO(GH-3604): Fix this failing assertion.
// Debug.Assert(offset == attestationInfo.Length);
Debug.Assert(offset == attestationInfo.Length);
}
catch (Exception exception)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,7 @@ public AttestationInfo(byte[] attestationInfo)
EnclaveDHInfo = new EnclaveDiffieHellmanInfo(attestationInfo, offset);
offset += Convert.ToInt32(EnclaveDHInfo.Size);

// TODO(GH-3604): Fix this failing assertion.
// Debug.Assert(offset == attestationInfo.Length, $"{offset} == {attestationInfo.Length}");
Debug.Assert(offset == attestationInfo.Length, $"{offset} == {attestationInfo.Length}");
}
}

Expand Down
Loading