Class IcaoMrtdWithPace

All Implemented Interfaces:
Card, CryptoCard, Cwa14890Card, Dni, MrtdLds1

public final class IcaoMrtdWithPace extends DnieNfc
Pasaporte accedido de forma inalámbrica mediante PACE.
  • Constructor Details

    • IcaoMrtdWithPace

      public IcaoMrtdWithPace(ApduConnection conn, CryptoHelper cryptoHlpr, CallbackHandler ch) throws IcaoException, ApduConnectionException
      Construye una clase que representa un MRTD accedido de forma inalámbrica mediante PACE.
      Parameters:
      conn - Conexión con el lector NFC.
      cryptoHlpr - Clase de utilidad de funciones criptográficas.
      ch - CallbackHandler que debe proporcionar, mediante un es.gob.jmulticard.callback.CustomTextInputCallback o un javax.security.auth.callback.TextInputCallback, el CAN o la MRZ del MRTD.
      Throws:
      IcaoException - Si no se puede establecer el canal PACE.
      ApduConnectionException - Si no se puede establecer la conexión NFC.
  • Method Details

    • getCardName

      public String getCardName()
      Description copied from class: AbstractSmartCard
      Obtiene el nombre de la tarjeta.
      Overrides:
      getCardName in class DnieNfc
      Returns:
      Nombre de la tarjeta
    • openSecureChannelIfNotAlreadyOpened

      public void openSecureChannelIfNotAlreadyOpened()
      Description copied from class: Dnie3
      Si no se había hecho anteriormente, establece y abre el canal seguro de PIN CWA-14890, solicita y comprueba el PIN e inmediatamente después y, si la verificación es correcta, establece el canal de usuario CWA-14890. Si falla algún punto del proceso, vuelve al modo inicial de conexión (sin canal seguro).
      Overrides:
      openSecureChannelIfNotAlreadyOpened in class DnieNfc
    • openSecureChannelIfNotAlreadyOpened

      public void openSecureChannelIfNotAlreadyOpened(boolean doChv)
      Description copied from class: Dnie
      Establece y abre el canal seguro CWA-14890 si no lo estaba ya.
      Overrides:
      openSecureChannelIfNotAlreadyOpened in class Dnie3
      Parameters:
      doChv - true si la apertura de canal seguro debe incluir la verificación de PIN, false si debe abrirse canal seguro sin verificar PIN.
    • sign

      public byte[] sign(byte[] data, String signAlgorithm, PrivateKeyReference privateKeyRef)
      Description copied from interface: CryptoCard
      Realiza una firma electrónica.
      Specified by:
      sign in interface CryptoCard
      Overrides:
      sign in class DnieNfc
      Parameters:
      data - Datos a firmar.
      signAlgorithm - Algoritmo de firma.
      privateKeyRef - Referencia a la clave privada de firma.
      Returns:
      Datos firmados (PKCS#1 v1.5).
    • toString

      public String toString()
      Overrides:
      toString in class Dnie
    • getCardSecurity

      public byte[] getCardSecurity() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el CardSecurity.
      Specified by:
      getCardSecurity in interface MrtdLds1
      Overrides:
      getCardSecurity in class Dnie3
      Returns:
      CardSecurity.
      Throws:
      IOException - Si no se puede leer el fichero.
    • getDg3

      public byte[] getDg3() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG3 (elementos de identificación adicionales - Dedos). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de administración esté previamente establecido.
      Specified by:
      getDg3 in interface MrtdLds1
      Overrides:
      getDg3 in class Dnie3
      Returns:
      DG3 (elementos de identificación adicionales - Dedos).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg4

      public byte[] getDg4() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG4 (elementos de identificación adicionales - Iris). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de administración esté previamente establecido.
      Specified by:
      getDg4 in interface MrtdLds1
      Overrides:
      getDg4 in class Dnie3
      Returns:
      DG4 (elementos de identificación adicionales - Iris).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg5

      public byte[] getDg5() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG5 (retrato exhibido). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg5 in interface MrtdLds1
      Overrides:
      getDg5 in class Dnie3
      Returns:
      DG5 (retrato exhibido).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg6

      public byte[] getDg6() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG6 (reservado para uso futuro). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg6 in interface MrtdLds1
      Overrides:
      getDg6 in class Dnie3
      Returns:
      DG6 (reservado para uso futuro).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg8

      public byte[] getDg8() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG8 (elemento datos). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg8 in interface MrtdLds1
      Overrides:
      getDg8 in class Dnie3
      Returns:
      DG7 (elemento datos).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg9

      public byte[] getDg9() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG9 (elemento estructura). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg9 in interface MrtdLds1
      Overrides:
      getDg9 in class Dnie3
      Returns:
      DG9 (elemento estructura).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg10

      public byte[] getDg10() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG10 (elemento sustancia). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg10 in interface MrtdLds1
      Overrides:
      getDg10 in class Dnie3
      Returns:
      DG10 (elemento sustancia).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg15

      public byte[] getDg15() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG15 (información de clave pública de autenticación activa). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg15 in interface MrtdLds1
      Overrides:
      getDg15 in class Dnie3
      Returns:
      DG15 (información de clave pública de autenticación activa).
      Throws:
      IOException - Si hay problemas leyendo el fichero.
    • getDg16

      public byte[] getDg16() throws IOException
      Description copied from interface: MrtdLds1
      Obtiene el DG16 (personas que han de notificarse). Devuelve el objeto binario sin tratar. Puede necesitar que el canal de usuario esté previamente establecido.
      Specified by:
      getDg16 in interface MrtdLds1
      Overrides:
      getDg16 in class Dnie3
      Returns:
      DG16 (personas que han de notificarse).
      Throws:
      IOException - Si hay problemas leyendo el fichero.