Skip to content

Commit

Permalink
Update Enclave Error messages to handle Attestation Protocol (#421)
Browse files Browse the repository at this point in the history
  • Loading branch information
cheenamalhotra committed Feb 12, 2020
1 parent 13a69bd commit bac3ab4
Show file tree
Hide file tree
Showing 9 changed files with 299 additions and 165 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1712,6 +1712,16 @@ internal static Exception EnclaveComputationsNotSupported()
return ADP.InvalidOperation(System.SRHelper.GetString(SR.TCE_EnclaveComputationsNotSupported));
}

internal static Exception AttestationURLNotSupported()
{
return ADP.InvalidOperation(System.SRHelper.GetString(SR.TCE_AttestationURLNotSupported));
}

internal static Exception AttestationProtocolNotSupported()
{
return ADP.InvalidOperation(System.SRHelper.GetString(SR.TCE_AttestationProtocolNotSupported));
}

internal static Exception EnclaveTypeNotReturned()
{
return ADP.InvalidOperation(System.SRHelper.GetString(SR.TCE_EnclaveTypeNotReturned));
Expand Down

Large diffs are not rendered by default.

26 changes: 22 additions & 4 deletions src/Microsoft.Data.SqlClient/netcore/src/Resources/SR.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 7 additions & 1 deletion src/Microsoft.Data.SqlClient/netcore/src/Resources/SR.resx
Original file line number Diff line number Diff line change
Expand Up @@ -1654,8 +1654,14 @@
<value>Invalid key store provider name specified. Key store provider names cannot be null or empty.</value>
</data>
<data name="TCE_EnclaveComputationsNotSupported" xml:space="preserve">
<value>You have specified the enclave attestation URL and attestation protocol in the connection string, but the SQL Server instance in use does not support enclave based computations.</value>
</data>
<data name="TCE_AttestationURLNotSupported" xml:space="preserve">
<value>You have specified the enclave attestation URL in the connection string, but the SQL Server instance in use does not support enclave based computations.</value>
</data>
<data name="TCE_AttestationProtocolNotSupported" xml:space="preserve">
<value>You have specified the attestation protocol in the connection string, but the SQL Server instance in use does not support enclave based computations.</value>
</data>
<data name="TCE_EnclaveProviderNotFound" xml:space="preserve">
<value>No enclave provider found for enclave type '{0}' and attestation protocol '{1}'. Please specify the correct attestation protocol in the connection string.</value>
</data>
Expand Down Expand Up @@ -1854,4 +1860,4 @@
<data name="SQLUDT_InvalidSize" xml:space="preserve">
<value>UDT size must be less than {1}, size: {0}</value>
</data>
</root>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -1730,6 +1730,16 @@ static internal Exception EnclaveComputationsNotSupported()
return ADP.InvalidOperation(StringsHelper.GetString(Strings.TCE_EnclaveComputationsNotSupported));
}

internal static Exception AttestationURLNotSupported()
{
return ADP.InvalidOperation(StringsHelper.GetString(Strings.TCE_AttestationURLNotSupported));
}

internal static Exception AttestationProtocolNotSupported()
{
return ADP.InvalidOperation(StringsHelper.GetString(Strings.TCE_AttestationProtocolNotSupported));
}

static internal Exception EnclaveTypeNotReturned()
{
return ADP.InvalidOperation(StringsHelper.GetString(Strings.TCE_EnclaveTypeNotReturned));
Expand Down
Loading

0 comments on commit bac3ab4

Please sign in to comment.