<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Could you please review the proposed fix for regression test</p>
    <p>BUGURL: <a class="moz-txt-link-freetext"
        href="https://bugs.openjdk.java.net/browse/JDK-8157603">https://bugs.openjdk.java.net/browse/JDK-8157603</a><br>
      WEBREV: <a
        href="http://cr.openjdk.java.net/%7Eakosarev/8157603/webrev.00/"><a class="moz-txt-link-freetext" href="http://cr.openjdk.java.net/~akosarev/8157603/webrev.00">http://cr.openjdk.java.net/~akosarev/8157603/webrev.00</a></a><br>
      <br>
      DESCRIPTION:<br>
      <b>    </b><span style="color: rgb(51, 51, 51); font-family:
        Arial, sans-serif; font-size: 14px; font-style: normal;
        font-variant: normal; font-weight: normal; letter-spacing:
        normal; line-height: 18.2px; orphans: auto; text-align: start;
        text-indent: 0px; text-transform: none; white-space: normal;
        widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px;
        display: inline !important; float: none; background-color:
        rgb(255, 255, 255);">Main problem is that we were not performing
        check that decryption into same buffer went correct.<span
          class="Apple-converted-space"> </span></span><br style="color:
        rgb(51, 51, 51); font-family: Arial, sans-serif; font-size:
        14px; font-style: normal; font-variant: normal; font-weight:
        normal; letter-spacing: normal; line-height: 18.2px; orphans:
        auto; text-align: start; text-indent: 0px; text-transform: none;
        white-space: normal; widows: 1; word-spacing: 0px;
        -webkit-text-stroke-width: 0px; background-color: rgb(255, 255,
        255);">
      <span style="color: rgb(51, 51, 51); font-family: Arial,
        sans-serif; font-size: 14px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 18.2px; orphans: auto; text-align: start;
        text-indent: 0px; text-transform: none; white-space: normal;
        widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px;
        display: inline !important; float: none; background-color:
        rgb(255, 255, 255);">    Instead, string created by decryption
        into another buffer was checked twice.</span></p>
    <p><span style="color: rgb(51, 51, 51); font-family: Arial,
        sans-serif; font-size: 14px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 18.2px; orphans: auto; text-align: start;
        text-indent: 0px; text-transform: none; white-space: normal;
        widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px;
        display: inline !important; float: none; background-color:
        rgb(255, 255, 255);">    Fix for the above issue was easy, but I
        also identified one more mistake:<span
          class="Apple-converted-space"> <span style="color: rgb(51,
            51, 51); font-family: Arial, sans-serif; font-size: 14px;
            font-style: normal; font-variant: normal; font-weight:
            normal; letter-spacing: normal; line-height: 18.2px;
            orphans: auto; text-align: start; text-indent: 0px;
            text-transform: none; white-space: normal; widows: 1;
            word-spacing: 0px; -webkit-text-stroke-width: 0px; display:
            inline !important; float: none; background-color: rgb(255,
            255, 255);"><span class="Apple-converted-space"></span></span><br
            style="color: rgb(51, 51, 51); font-family: Arial,
            sans-serif; font-size: 14px; font-style: normal;
            font-variant: normal; font-weight: normal; letter-spacing:
            normal; line-height: 18.2px; orphans: auto; text-align:
            start; text-indent: 0px; text-transform: none; white-space:
            normal; widows: 1; word-spacing: 0px;
            -webkit-text-stroke-width: 0px; background-color: rgb(255,
            255, 255);">
                 <span style="color: rgb(51, 51, 51); font-family:
            Arial, sans-serif; font-size: 14px; font-style: normal;
            font-variant: normal; font-weight: normal; letter-spacing:
            normal; line-height: 18.2px; orphans: auto; text-align:
            start; text-indent: 0px; text-transform: none; white-space:
            normal; widows: 1; word-spacing: 0px;
            -webkit-text-stroke-width: 0px; display: inline !important;
            float: none; background-color: rgb(255, 255, 255);">Initially,
            we were not calculating size of encrypted/decrypted messages
            when they were stored into the same buffer. After my fix
            their lengths will be calculated using <span
              class="Apple-converted-space">values returned from <i>update
              </i>& <i>doFinal </i>methods.</span></span></span><br>
      </span></p>
    <p><span style="color: rgb(51, 51, 51); font-family: Arial,
        sans-serif; font-size: 14px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 18.2px; orphans: auto; text-align: start;
        text-indent: 0px; text-transform: none; white-space: normal;
        widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px;
        display: inline !important; float: none; background-color:
        rgb(255, 255, 255);"><span class="Apple-converted-space"><span
            style="color: rgb(51, 51, 51); font-family: Arial,
            sans-serif; font-size: 14px; font-style: normal;
            font-variant: normal; font-weight: normal; letter-spacing:
            normal; line-height: 18.2px; orphans: auto; text-align:
            start; text-indent: 0px; text-transform: none; white-space:
            normal; widows: 1; word-spacing: 0px;
            -webkit-text-stroke-width: 0px; display: inline !important;
            float: none; background-color: rgb(255, 255, 255);">   
            Moreover, I applied additional check on the length of
            crypted/decrypted messages.<br>
          </span></span></span></p>
    <br>
    Changes were successfully tested by JPRT.<br>
    <p> <br>
      Best regards,<br>
      Artem Kosarev.</p>
  </body>
</html>