Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-5061398

RFE: BigInteger is immutable

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Won't Fix
    • Icon: P4 P4
    • None
    • 1.4.2
    • core-libs
    • x86
    • windows_2000



      Name: rmT116609 Date: 06/10/2004


      A DESCRIPTION OF THE REQUEST :
      As BigInteger is often used in cryptographic applications to hold sensitive secrets (Private Keys), it's immutable makes it hard to preserve these secrets, as operating on the sensitive BigIntegers will result in the secret being copied all over memory, or even likely getting swapped to disk.

      JUSTIFICATION :
      Having control over cryptographic secrets is a must for many secure applications.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      A mutable BigInteger so control over destruction of cryptographic secrets can be achieved.
      ACTUAL -
      BigInteger copies the bytearray used in every operation as part of the operation to ensure the immutability invariant. This makes it impossible to control destruction of cryptograpic secrets.

      (Incident Review ID: 277045)
      ======================================================================

            darcy Joe Darcy
            rmandalasunw Ranjith Mandala (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: