Quantcast

Upgrading from 1.46 to .56

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Upgrading from 1.46 to .56

tech user
Hi All,

I am trying to upgrade from 1.46 to any version that's greater than 1.54 .

But to my surprise when we changed to use the library we are getting a
lot of compile issues.Many constructors have been changed

Is there any guide to know what changed from 1.46

I see that Constructors have been modified

Here is the list of classes that we were using in our old code

new PGPSecretKeyRing(byte[] encoded)
new PGPPublicKeyRing(byte[] encoded)
new PGPObjectFactory(inputStream)


new PGPPublicKeyRing(PGPUtil.getDecoderStream(keyIn));

final PGPEncryptedDataGenerator generator = new
PGPEncryptedDataGenerator(algorithm, true,
                new SecureRandom(), provider);
        for (PGPPublicKey key:keys){
            generator.addMethod(key);
        }




Here is maven dependency
 current :
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcpg-jdk15on</artifactId><version>1.56</version></dependency>
    <dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk15on</artifactId><version>1.56</version></dependency>

Old :

<dependency>
        <groupId>org.bouncycastle</groupId>
        <artifactId>bcpg-jdk16</artifactId>
        <version>1.46</version>
      </dependency>
      <dependency>
        <groupId>org.bouncycastle</groupId>
        <artifactId>bcprov-jdk16</artifactId>
        <version>1.46</version>
      </dependency>






Thanks in Advance

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Upgrading from 1.46 to .56

Amedee Van Gasse
Op 04-05-17 om 21:19 schreef Sivaji Adurthy:
> Hi All,
>
> I am trying to upgrade from 1.46 to any version that's greater than 1.54 .
>
> But to my surprise when we changed to use the library we are getting a
> lot of compile issues.Many constructors have been changed
>
> Is there any guide to know what changed from 1.46

Yes!

http://www.bouncycastle.org/wiki/display/JA1/Porting+from+earlier+BC+releases+to+1.47+and+later


--
Amedee Van Gasse
QA Engineer | iText Software BVBA
[hidden email]
http://itextpdf.com

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Upgrading from 1.46 to .56

Erdem Memisyazici
This may or may not help but I felt like this is a good thread to
share.  We came across a problem upgrading 1.53 to 1.54 where we
realized that org.bouncycastle.asn1.ASN1Primitive#fromByteArray(encoded)
began validating stream contents so I switched to
org.bouncycastle.asn1.ASN1InputStream
(https://github.com/vt-middleware/cryptacular/pull/30/files).  If anyone
out there had a similar issue, I hope this helps.

--Erdem


On 05/05/2017 03:47 AM, Amedee Van Gasse wrote:

> Op 04-05-17 om 21:19 schreef Sivaji Adurthy:
>> Hi All,
>>
>> I am trying to upgrade from 1.46 to any version that's greater than
>> 1.54 .
>>
>> But to my surprise when we changed to use the library we are getting a
>> lot of compile issues.Many constructors have been changed
>>
>> Is there any guide to know what changed from 1.46
>
> Yes!
>
> http://www.bouncycastle.org/wiki/display/JA1/Porting+from+earlier+BC+releases+to+1.47+and+later
>
>
>


Loading...