background preloader

Programming

Facebook Twitter

PSSParameterSpec (Java Platform SE 6) Java.lang.Object java.security.spec.PSSParameterSpec All Implemented Interfaces: AlgorithmParameterSpec public class PSSParameterSpecextends Objectimplements AlgorithmParameterSpec This class specifies a parameter spec for RSA-PSS signature scheme, as defined in the PKCS#1 v2.1 standard. Its ASN.1 definition in PKCS#1 standard is described below: RSASSA-PSS-params ::= SEQUENCE { hashAlgorithm [0] OAEP-PSSDigestAlgorithms DEFAULT sha1, maskGenAlgorithm [1] PKCS1MGFAlgorithms DEFAULT mgf1SHA1, saltLength [2] INTEGER DEFAULT 20, trailerField [3] INTEGER DEFAULT 1 } where Note: the PSSParameterSpec.DEFAULT uses the following: message digest -- "SHA-1" mask generation function (mgf) -- "MGF1" parameters for mgf -- MGF1ParameterSpec.SHA1 SaltLength -- 20 TrailerField -- 1 Since: See Also: MGF1ParameterSpec, AlgorithmParameterSpec, Signature public static final PSSParameterSpec DEFAULT The PSS parameter set with all default values.

PSSParameterSpec Parameters: mdName - the algorithm name of the hash function. PKCS#1 signature padding - www.ms-news.net. Cryptography Reference. CRYPT_RSA_SSA_PSS_PARAMETERS Structure. The CRYPT_RSA_SSA_PSS_PARAMETERS structure contains the parameters for an RSA PKCS #1 v2.1 signature. This structure is used with the PKCS_RSA_SSA_PSS_PARAMETERS and szOID_RSA_SSA_PSS encoding types. Syntax typedef struct _CRYPT_RSA_SSA_PSS_PARAMETERS { CRYPT_ALGORITHM_IDENTIFIER HashAlgorithm; CRYPT_MASK_GEN_ALGORITHM MaskGenAlgorithm; DWORD dwSaltLength; DWORD dwTrailerField; } CRYPT_RSA_SSA_PSS_PARAMETERS, *PCRYPT_RSA_SSA_PSS_PARAMETERS; Members HashAlgorithm MaskGenAlgorithm dwSaltLength The octet length of the salt. DwTrailerField The trailer field number. Requirements. CERT_CAPABILITY. RSACryptoServiceProvider.Encrypt Method (System.Security.Cryptog.

Public byte[] Encrypt( byte[] rgb, bool fOAEP ) Parameters rgb Type: System.Byte[] The data to be encrypted. fOAEP Type: System.Boolean The following table describes the padding supported by different versions of Microsoft Windows and the maximum length of rgb allowed by the different combinations of operating systems and padding. .NET Framework Supported in: 4.5.1, 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0 .NET Framework Client Profile Supported in: 4, 3.5 SP1 .NET for Windows Phone apps Supported in: Windows Phone 8.1, Windows Phone 8, Silverlight 8.1 Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

RSACryptoServiceProvider Padding PKCS1.