diff --git a/modules/openapi-generator/src/main/resources/csharp-netcore/HttpSigningConfiguration.mustache b/modules/openapi-generator/src/main/resources/csharp-netcore/HttpSigningConfiguration.mustache index f80e584c666..58a961b5da3 100644 --- a/modules/openapi-generator/src/main/resources/csharp-netcore/HttpSigningConfiguration.mustache +++ b/modules/openapi-generator/src/main/resources/csharp-netcore/HttpSigningConfiguration.mustache @@ -741,15 +741,6 @@ namespace {{packageName}}.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClient-ConditionalSerialization/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClient-ConditionalSerialization/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClient-ConditionalSerialization/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClient-ConditionalSerialization/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClient-httpclient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClient-httpclient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClient-httpclient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClient-httpclient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClient-net47/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClient-net47/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClient-net47/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClient-net47/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClient-net5.0/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClient-net5.0/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClient-net5.0/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClient-net5.0/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClient/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported"); diff --git a/samples/client/petstore/csharp-netcore/OpenAPIClientCore/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs b/samples/client/petstore/csharp-netcore/OpenAPIClientCore/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs index f3eaf3c5ade..6a8f9c8dc01 100644 --- a/samples/client/petstore/csharp-netcore/OpenAPIClientCore/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs +++ b/samples/client/petstore/csharp-netcore/OpenAPIClientCore/src/Org.OpenAPITools/Client/HttpSigningConfiguration.cs @@ -749,15 +749,6 @@ namespace Org.OpenAPITools.Client { keyType = PrivateKeyType.ECDSA; } - else if (key[0].Contains(ecPrivateKeyHeader) && - key[key.Length - 1].ToString().Contains(ecPrivateKeyFooter)) - { - - // this type of key can hold many type different types of private key, but here due lack of pem header - // Considering this as EC key - //TODO :- update the key based on oid - keyType = PrivateKeyType.ECDSA; - } else { throw new Exception("Either the key is invalid or key is not supported");