81. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 9/25/2018 2:13:01 PM Central Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

81.1 Files compared

# Location File Last Modified
1 build 3.zip\build 3\MHLTH_YS_137_Source\JavaScript\resources\javaJDF-1.8.0\src\com\sun\crypto\provider BlowfishKeyGenerator.java Mon Jan 22 14:46:50 2018 UTC
2 build 3.zip\build 3\MHLTH_YS_137_Source\JavaScript\resources\javaJDF-1.8.0\src\com\sun\crypto\provider BlowfishKeyGenerator.java Wed Sep 12 16:22:14 2018 UTC

81.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 2 228
Changed 1 2
Inserted 0 0
Removed 0 0

81.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

81.4 Active regular expressions

No regular expressions were active.

81.5 Comparison detail

  1   /*
  2    * Copyrig ht (c) 199 8, 2013, O racle and/ or its aff iliates. A ll rights  reserved.
  3    * DO NOT  ALTER OR R EMOVE COPY RIGHT NOTI CES OR THI S FILE HEA DER.
  4    *
  5    * This co de is free  software;  you can r edistribut e it and/o r modify i t
  6    * under t he terms o f the GNU  General Pu blic Licen se version  2 only, a s
  7    * publish ed by the  Free Softw are Founda tion.  Ora cle design ates this
  8    * particu lar file a s subject  to the "Cl asspath" e xception a s provided
  9    * by Orac le in the  LICENSE fi le that ac companied  this code.
  10    *
  11    * This co de is dist ributed in  the hope  that it wi ll be usef ul, but WI THOUT
  12    * ANY WAR RANTY; wit hout even  the implie d warranty  of MERCHA NTABILITY  or
  13    * FITNESS  FOR A PAR TICULAR PU RPOSE.  Se e the GNU  General Pu blic Licen se
  14    * version  2 for mor e details  (a copy is  included  in the LIC ENSE file  that
  15    * accompa nied this  code).
  16    *
  17    * You sho uld have r eceived a  copy of th e GNU Gene ral Public  License v ersion
  18    * 2 along  with this  work; if  not, write  to the Fr ee Softwar e Foundati on,
  19    * Inc., 5 1 Franklin  St, Fifth  Floor, Bo ston, MA 0 2110-1301  USA.
  20    *
  21    * Please  contact Or acle, 500  Oracle Par kway, Redw ood Shores , CA 94065  USA
  22    * or visi t www.orac le.com if  you need a dditional  informatio n or have  any
  23    * questio ns.
  24    */
  25  
  26   package co m.sun.cryp to.provide r;
  27  
  28   import jav a.security .SecureRan dom;
  29   import jav a.security .InvalidPa rameterExc eption;
  30   import jav a.security .InvalidAl gorithmPar ameterExce ption;
  31   import jav a.security .spec.Algo rithmParam eterSpec;
  32   import jav ax.crypto. KeyGenerat orSpi;
  33   import jav ax.crypto. SecretKey;
  34   import jav ax.crypto. spec.Secre tKeySpec;
  35  
  36   /**
  37    * This cl ass genera tes a  PW        key for us e with the  Blowfish  algorithm.
  38    *
  39    * @author  Jan Luehe
  40    *
  41    */
  42  
  43   public fin al class B lowfishKey Generator  extends Ke yGenerator Spi {
  44  
  45       privat e SecureRa ndom rando m = null;
  46       privat e int keys ize = 16;  // default  keysize ( in number  of bytes)
  47  
  48       /**
  49        * Emp ty constru ctor
  50        */
  51       public  BlowfishK eyGenerato r() {
  52       }
  53  
  54       /**
  55        * Ini tializes t his key ge nerator.
  56        *
  57        * @pa ram random  the sourc e of rando mness for  this gener ator
  58        */
  59       protec ted void e ngineInit( SecureRand om random)  {
  60           th is.random  = random;
  61       }
  62  
  63       /**
  64        * Ini tializes t his key ge nerator wi th the spe cified par ameter
  65        * set  and a use r-provided  source of  randomnes s.
  66        *
  67        * @pa ram params  the key g eneration  parameters
  68        * @pa ram random  the sourc e of rando mness for  this key g enerator
  69        *
  70        * @ex ception In validAlgor ithmParame terExcepti on if <cod e>params</ code> is
  71        * ina ppropriate  for this  key genera tor
  72        */
  73       protec ted void e ngineInit( AlgorithmP arameterSp ec params,
  74                                    SecureRand om random)
  75           th rows Inval idAlgorith mParameter Exception
  76       {
  77           th row new In validAlgor ithmParame terExcepti on
  78                ("Blowfi sh key gen eration do es not tak e any para meters");
  79       }
  80  
  81       /**
  82        * Ini tializes t his key ge nerator fo r a certai n keysize,  using the  given
  83        * sou rce of ran domness.
  84        *
  85        * @pa ram keysiz e the keys ize. This  is an algo rithm-spec ific
  86        * met ric specif ied in num ber of bit s.
  87        * @pa ram random  the sourc e of rando mness for  this key g enerator
  88        */
  89       protec ted void e ngineInit( int keysiz e, SecureR andom rand om) {
  90           if  (((keysiz e % 8) !=  0) || (key size < 32)  || (keysi ze > 448))  {
  91                throw ne w InvalidP arameterEx ception("K eysize mus t be "
  92                                                       +  "multiple  of 8, and  can "
  93                                                       +  "only rang e from 32  to 448 "
  94                                                       +  "(inclusiv e)");
  95           }
  96           th is.keysize  = keysize  / 8;
  97           th is.engineI nit(random );
  98       }
  99  
  100       /**
  101        * Gen erates a B lowfish ke y.
  102        *
  103        * @re turn the n ew Blowfis h key
  104        */
  105       protec ted Secret Key engine GenerateKe y() {
  106           if  (this.ran dom == nul l) {
  107                this.ran dom = SunJ CE.getRand om();
  108           }
  109  
  110           by te[] keyBy tes = new  byte[this. keysize];
  111           th is.random. nextBytes( keyBytes);
  112  
  113           re turn new S ecretKeySp ec(keyByte s, "Blowfi sh");
  114       }
  115   }