Home
last modified time | relevance | path

Searched refs:spec (Results 1 – 25 of 35) sorted by relevance

12

/cts/tests/tests/keystore/src/android/keystore/cts/
DKeyGenParameterSpecTest.java26 import java.security.spec.AlgorithmParameterSpec;
27 import java.security.spec.ECGenParameterSpec;
43 KeyGenParameterSpec spec = new KeyGenParameterSpec.Builder( in testDefaults() local
47 assertEquals("arbitrary", spec.getKeystoreAlias()); in testDefaults()
48 assertEquals(KeyProperties.PURPOSE_ENCRYPT, spec.getPurposes()); in testDefaults()
49 assertNull(null, spec.getAlgorithmParameterSpec()); in testDefaults()
50 MoreAsserts.assertEmpty(Arrays.asList(spec.getBlockModes())); in testDefaults()
51 assertEquals(DEFAULT_CERT_NOT_BEFORE, spec.getCertificateNotBefore()); in testDefaults()
52 assertEquals(DEFAULT_CERT_NOT_AFTER, spec.getCertificateNotAfter()); in testDefaults()
53 assertEquals(DEFAULT_CERT_SERIAL_NUMBER, spec.getCertificateSerialNumber()); in testDefaults()
[all …]
DKeyProtectionTest.java32 KeyProtection spec = new KeyProtection.Builder(KeyProperties.PURPOSE_ENCRYPT) in testDefaults() local
35 assertEquals(KeyProperties.PURPOSE_ENCRYPT, spec.getPurposes()); in testDefaults()
36 MoreAsserts.assertEmpty(Arrays.asList(spec.getBlockModes())); in testDefaults()
37 assertFalse(spec.isDigestsSpecified()); in testDefaults()
39 spec.getDigests(); in testDefaults()
42 MoreAsserts.assertEmpty(Arrays.asList(spec.getEncryptionPaddings())); in testDefaults()
43 assertNull(spec.getKeyValidityStart()); in testDefaults()
44 assertNull(spec.getKeyValidityForOriginationEnd()); in testDefaults()
45 assertNull(spec.getKeyValidityForConsumptionEnd()); in testDefaults()
46 assertTrue(spec.isRandomizedEncryptionRequired()); in testDefaults()
[all …]
DKeyPairGeneratorSpecTest.java43 KeyPairGeneratorSpec spec = new KeyPairGeneratorSpec.Builder(getContext()) in testBuilder_Unencrypted_Success() local
51 assertEquals("Context should be the one specified", getContext(), spec.getContext()); in testBuilder_Unencrypted_Success()
53 assertEquals("Alias should be the one specified", TEST_ALIAS_1, spec.getKeystoreAlias()); in testBuilder_Unencrypted_Success()
55 assertEquals("subjectDN should be the one specified", TEST_DN_1, spec.getSubjectDN()); in testBuilder_Unencrypted_Success()
57 assertEquals("startDate should be the one specified", NOW, spec.getStartDate()); in testBuilder_Unencrypted_Success()
59 assertEquals("endDate should be the one specified", NOW_PLUS_10_YEARS, spec.getEndDate()); in testBuilder_Unencrypted_Success()
61 assertFalse("encryption flag should not be on", spec.isEncryptionRequired()); in testBuilder_Unencrypted_Success()
65 KeyPairGeneratorSpec spec = new KeyPairGeneratorSpec.Builder(getContext()) in testBuilder_Encrypted_Success() local
74 assertEquals("Context should be the one specified", getContext(), spec.getContext()); in testBuilder_Encrypted_Success()
76 assertEquals("Alias should be the one specified", TEST_ALIAS_1, spec.getKeystoreAlias()); in testBuilder_Encrypted_Success()
[all …]
DAESCBCCipherTestBase.java20 import java.security.spec.AlgorithmParameterSpec;
21 import java.security.spec.InvalidParameterSpecException;
23 import javax.crypto.spec.IvParameterSpec;
54 IvParameterSpec spec = params.getParameterSpec(IvParameterSpec.class); in getIv() local
55 return spec.getIV(); in getIv()
DAESCTRCipherTestBase.java20 import java.security.spec.AlgorithmParameterSpec;
21 import java.security.spec.InvalidParameterSpecException;
23 import javax.crypto.spec.IvParameterSpec;
54 IvParameterSpec spec = params.getParameterSpec(IvParameterSpec.class); in getIv() local
55 return spec.getIV(); in getIv()
DECCurves.java20 import java.security.spec.ECField;
21 import java.security.spec.ECFieldFp;
22 import java.security.spec.ECParameterSpec;
23 import java.security.spec.ECPoint;
24 import java.security.spec.EllipticCurve;
DKeyFactoryTest.java39 import java.security.spec.ECPrivateKeySpec;
40 import java.security.spec.ECPublicKeySpec;
41 import java.security.spec.InvalidKeySpecException;
42 import java.security.spec.KeySpec;
43 import java.security.spec.PKCS8EncodedKeySpec;
44 import java.security.spec.RSAPrivateKeySpec;
45 import java.security.spec.RSAPublicKeySpec;
46 import java.security.spec.X509EncodedKeySpec;
58 import javax.crypto.spec.SecretKeySpec;
240 ECPublicKeySpec spec = in testGetKeySpecWithKeystorePublicKeyAcceptsTransparentKeySpec() local
[all …]
DTestUtils.java51 import java.security.spec.ECParameterSpec;
52 import java.security.spec.EllipticCurve;
53 import java.security.spec.InvalidKeySpecException;
54 import java.security.spec.PKCS8EncodedKeySpec;
64 import javax.crypto.spec.SecretKeySpec;
486 KeyProtection spec, Integer newPurposes) { in buildUponInternal() argument
487 int purposes = (newPurposes == null) ? spec.getPurposes() : newPurposes; in buildUponInternal()
489 result.setBlockModes(spec.getBlockModes()); in buildUponInternal()
490 if (spec.isDigestsSpecified()) { in buildUponInternal()
491 result.setDigests(spec.getDigests()); in buildUponInternal()
[all …]
DAESECBCipherTestBase.java20 import java.security.spec.AlgorithmParameterSpec;
21 import java.security.spec.InvalidParameterSpecException;
DAESGCMCipherTestBase.java22 import java.security.spec.AlgorithmParameterSpec;
23 import java.security.spec.InvalidParameterSpecException;
27 import javax.crypto.spec.GCMParameterSpec;
61 GCMParameterSpec spec = params.getParameterSpec(GCMParameterSpec.class); in getIv() local
62 return spec.getIV(); in getIv()
DKeyGeneratorTest.java31 import java.security.spec.AlgorithmParameterSpec;
32 import java.security.spec.ECGenParameterSpec;
222 KeyGenParameterSpec spec; in testAesKeySupportedSizes() local
224 spec = TestUtils.buildUpon(goodSpec.setKeySize(i)).build(); in testAesKeySupportedSizes()
227 spec = TestUtils.buildUpon(goodSpec.setKeySize(i)).build(); in testAesKeySupportedSizes()
235 keyGenerator.init(spec, rng); in testAesKeySupportedSizes()
241 keyGenerator.init(spec, rng); in testAesKeySupportedSizes()
263 KeyGenParameterSpec spec; in testHmacKeySupportedSizes() local
265 spec = getWorkingSpec().setKeySize(i).build(); in testHmacKeySupportedSizes()
268 spec = getWorkingSpec().setKeySize(i).build(); in testHmacKeySupportedSizes()
[all …]
DBlockCipherTestBase.java36 import java.security.spec.AlgorithmParameterSpec;
37 import java.security.spec.InvalidParameterSpecException;
48 import javax.crypto.spec.IvParameterSpec;
49 import javax.crypto.spec.SecretKeySpec;
1337 protected void init(int opmode, Key key, AlgorithmParameters spec) in init() argument
1339 mCipher.init(opmode, key, spec); in init()
1343 protected void init(int opmode, Key key, AlgorithmParameters spec, SecureRandom random) in init() argument
1345 mCipher.init(opmode, key, spec, random); in init()
1349 protected void init(int opmode, Key key, AlgorithmParameterSpec spec) in init() argument
1351 mCipher.init(opmode, key, spec); in init()
[all …]
DKeyPairGeneratorTest.java46 import java.security.spec.AlgorithmParameterSpec;
47 import java.security.spec.ECGenParameterSpec;
48 import java.security.spec.ECParameterSpec;
49 import java.security.spec.RSAKeyGenParameterSpec;
157 KeyPairGeneratorSpec spec = new KeyPairGeneratorSpec.Builder(getContext()) in testInitialize_LegacySpec() local
164 getRsaGenerator().initialize(spec); in testInitialize_LegacySpec()
165 getRsaGenerator().initialize(spec, new SecureRandom()); in testInitialize_LegacySpec()
167 getEcGenerator().initialize(spec); in testInitialize_LegacySpec()
168 getEcGenerator().initialize(spec, new SecureRandom()); in testInitialize_LegacySpec()
172 KeyGenParameterSpec spec = new KeyGenParameterSpec.Builder( in testInitialize_ModernSpec() local
[all …]
DSecretKeyFactoryTest.java31 import java.security.spec.InvalidKeySpecException;
42 import javax.crypto.spec.SecretKeySpec;
DCipherTest.java33 import java.security.spec.AlgorithmParameterSpec;
34 import java.security.spec.MGF1ParameterSpec;
48 import javax.crypto.spec.GCMParameterSpec;
49 import javax.crypto.spec.IvParameterSpec;
50 import javax.crypto.spec.OAEPParameterSpec;
51 import javax.crypto.spec.PSource;
52 import javax.crypto.spec.SecretKeySpec;
440 OAEPParameterSpec spec = params.getParameterSpec(OAEPParameterSpec.class); in testCiphertextGeneratedByHighestPriorityProviderDecryptsByAndroidKeyStore() local
442 ((MGF1ParameterSpec) spec.getMGFParameters()) in testCiphertextGeneratedByHighestPriorityProviderDecryptsByAndroidKeyStore()
445 spec.getDigestAlgorithm(), in testCiphertextGeneratedByHighestPriorityProviderDecryptsByAndroidKeyStore()
DAESCipherNistCavpKatTest.java36 import javax.crypto.spec.IvParameterSpec;
37 import javax.crypto.spec.SecretKeySpec;
/cts/tests/tests/widget/src/android/widget/cts/
DGridLayoutTest.java34 import static android.widget.GridLayout.spec;
151 GridLayout.spec(0), in testCheckLayoutParams()
152 GridLayout.spec(0))); in testCheckLayoutParams()
174 GridLayout.LayoutParams lp = new GridLayout.LayoutParams(spec(0), spec(0)); in populate()
182 GridLayout.LayoutParams lp = new GridLayout.LayoutParams(spec(row), spec(0)); in populate()
193 GridLayout.LayoutParams lp = new GridLayout.LayoutParams(spec(0), spec(col)); in populate()
207 GridLayout.LayoutParams lp = new GridLayout.LayoutParams(spec(row), spec(col)); in populate()
/cts/tools/signature-tools/
Dsig-check57 --from sig ${ANDROID_BUILD_TOP}/cts/tools/signature-tools/spec/android.spec \
80 java.security.spec \
94 javax.crypto.spec \
DTODO.txt4 Add more spec
Dsig-create77 java.security.spec \
91 javax.crypto.spec \
DREADME.txt50 spec : various input files to try the tool
/cts/tools/dex-tools/
DREADME.txt5 It is designed to be fast and close to the spec.
18 doc : dex file spec on which this parser is based
/cts/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/
DKeyManagementTest.java39 import java.security.spec.InvalidKeySpecException;
40 import java.security.spec.PKCS8EncodedKeySpec;
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DDelegatedCertInstallerTest.java38 import java.security.spec.InvalidKeySpecException;
39 import java.security.spec.PKCS8EncodedKeySpec;
/cts/hostsidetests/devicepolicy/app/CertInstaller/src/com/android/cts/certinstaller/
DCertInstallerActivity.java30 import java.security.spec.PKCS8EncodedKeySpec;

12