com.ibm.crypto.hdwrCCA.provider

Class RACFOutputStream

  • java.lang.Object
    • java.io.OutputStream
      • com.ibm.crypto.hdwrCCA.provider.RACFOutputStream
  • All Implemented Interfaces:
    java.io.Closeable, java.io.Flushable, java.lang.AutoCloseable


    public class RACFOutputStream
    extends java.io.OutputStream
    The RACFOutputStream extends OutputStream and is for use by the JceRACFKeyStore to write certificates and private keys to RACF.
    • Constructor Summary

      Constructors 
      Constructor and Description
      RACFOutputStream(java.lang.String userID, java.lang.String ringid, char[] passwd)
      Constructs an instance of a RACFOutputStream.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void close()
      Close the RACFOutputStream.
      void flush()
      Flush the RACFOuputStream.
      void write(byte[] b)
      Write data to the RACFOutputStream from a byte array.
      void write(byte[] b, int off, int len)
      Write data to the RACFOutputStream from a byte array.
      void write(int b)
      Writes b.length bytes from the specified int to this output stream
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RACFOutputStream

        public RACFOutputStream(java.lang.String userID,
                                java.lang.String ringid,
                                char[] passwd)
                         throws java.io.IOException
        Constructs an instance of a RACFOutputStream. A RACFOutputStream is used to write certificates and keys to a RACF Key Ring.
        Parameters:
        userID - a string containing the ID of the user that owns the keyring
        ringid - a string containing the name of the RACF key ring
        passwd - a character array containing the password for the keystore
        Throws:
        java.io.IOException - writing keys/certificates to the key ring.
    • Method Detail

      • write

        public void write(int b)
                   throws java.io.IOException
        Writes b.length bytes from the specified int to this output stream
        Specified by:
        write in class java.io.OutputStream
        Parameters:
        b - the data
        Throws:
        java.io.IOException - if RACFOutputStream is closed
      • write

        public void write(byte[] b)
                   throws java.io.IOException
        Write data to the RACFOutputStream from a byte array.
        Overrides:
        write in class java.io.OutputStream
        Parameters:
        b - a byte array that will contain the data for the RACFInputStream
        Throws:
        java.io.IOException - if RACFOutputStream is closed
      • write

        public void write(byte[] b,
                          int off,
                          int len)
                   throws java.io.IOException
        Write data to the RACFOutputStream from a byte array.
        Overrides:
        write in class java.io.OutputStream
        Parameters:
        b - a byte array that will contain the data for the RACFInputStream
        off -
        len -
        Throws:
        java.io.IOException - if RACFOutputStream is closed
      • close

        public void close()
                   throws java.io.IOException
        Close the RACFOutputStream.
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface java.lang.AutoCloseable
        Overrides:
        close in class java.io.OutputStream
        Throws:
        java.io.IOException
      • flush

        public void flush()
                   throws java.io.IOException
        Flush the RACFOuputStream. Parse the accumulated entries added from the RACF KeyStore into Entry objects. Then, write the entry object data into a buffer for the JNI code to parse.
        Specified by:
        flush in interface java.io.Flushable
        Overrides:
        flush in class java.io.OutputStream
        Throws:
        java.io.IOException
� Portions Copyright 1997, 2022 IBM Corporation. All rights reserved. � Portions Copyright 1997, 2022, Oracle and/or its affiliates. All rights reserved.