Lines Matching defs:key

41  * cryptographic keys of type <code>Key</code>) into <I>key specifications</I>
42 * (transparent representations of the underlying key material), and vice
44 * Secret key factories operate only on secret (symmetric) keys.
47 * key object from a given key specification (key material), or to retrieve
48 * the underlying key material of a key object in a suitable format.
51 * to find out which key specifications are supported by the
55 * For example, the DES secret-key factory supplied by the "SunJCE" provider
57 * keys, and that provider's secret-key factory for Triple DES keys supports
106 * @param algorithm the secret-key algorithm
139 * @param algorithm the standard name of the requested secret-key
174 * @param algorithm the standard name of the requested secret-key
218 * @param algorithm the standard name of the requested secret-key
316 * Generates a <code>SecretKey</code> object from the provided key
317 * specification (key material).
319 * @param keySpec the specification (key material) of the secret key
321 * @return the secret key
323 * @exception InvalidKeySpecException if the given key specification
324 * is inappropriate for this secret-key factory to produce a secret key.
347 ("Could not generate secret key", failure);
351 * Returns a specification (key material) of the given key object
354 * @param key the key
355 * @param keySpec the requested format in which the key material shall be
358 * @return the underlying key specification (key material) in the
361 * @exception InvalidKeySpecException if the requested key specification is
362 * inappropriate for the given key (e.g., the algorithms associated with
363 * <code>key</code> and <code>keySpec</code> do not match, or
364 * <code>key</code> references a key on a cryptographic hardware device
366 * key), or the given key cannot be dealt with
367 * (e.g., the given key has an algorithm or format not supported by this
368 * secret-key factory).
370 public final KeySpec getKeySpec(SecretKey key, Class keySpec)
373 return spi.engineGetKeySpec(key, keySpec);
379 return mySpi.engineGetKeySpec(key, keySpec);
391 ("Could not get key spec", failure);
395 * Translates a key object, whose provider may be unknown or potentially
396 * untrusted, into a corresponding key object of this secret-key factory.
398 * @param key the key whose provider is unknown or untrusted
400 * @return the translated key
402 * @exception InvalidKeyException if the given key cannot be processed
403 * by this secret-key factory.
405 public final SecretKey translateKey(SecretKey key)
408 return spi.engineTranslateKey(key);
414 return mySpi.engineTranslateKey(key);
426 ("Could not translate key", failure);