all groups > dotnet web services enhancements > july 2005 >
You're in the

dotnet web services enhancements

group:

Using rsa-sha1 for digital signatures


Using rsa-sha1 for digital signatures Sam
7/21/2005 1:30:27 PM
dotnet web services enhancements:
I want to sign a SOAP body using WSE 3.0

It looks like the algorithm chosen by default is
"http://www.w3.org/2000/09/xmldsig#hmac-sha1"

How do I switch this to use the agorithm
http://www.w3.org/2000/09/xmldsig#rsa-sha1

Any ideas/help ? I couldnt find this in the options
in the WSE config editor ?

Thanks
Re: Using rsa-sha1 for digital signatures Pablo Cibraro
8/2/2005 10:42:08 AM
Hi,
You can do that by code or configuration.

Configuration: Using the "keyAlgorithm" element.

<microsoft.web.services3>
<security>
<binarySecurityTokenManager>
<add
type="Microsoft.Web.Services3.Security.Tokens.X509SecurityTokenManager,
Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35"
valueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3">

<keyAlgorithm name="RSA15"/>
</add>
</binarySecurityTokenManager>
</security>
</microsoft.web.services3>

Code:

SecurityTokenManager manager =
(SecurityTokenManager)SecurityManager.GetSecurityTokenManagerByValueType("http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3");
manager.DefaultKeyAlgorithm = "RSA15";

Best regards,
Pablo Cibraro
www.lagashsystems.com



[quoted text, click to view]

AddThis Social Bookmark Button