Integration and Testing

Authorize.Net API questions and help with your payment integration.

Reply
Highlighted
Member
Posts: 3
Registered: ‎05-22-2017

SDK & TLS1.2

Hello,

The suggested fix didn't solve the TLS issue


Environment information:
Google App Engine ( GAE )
Java 7

We set the default TLS to 1.2 ( following documentation https://blogs.oracle.com/java-platform-group/diagnosing-tls,-ssl,-and-https ) but still we get the same issue, we passed this by only updating/fixing your SDK to support TLS 1.2 , and here is some detail:

 

Posts: 492
Topics: 0
Kudos: 99
Blog Posts: 0
Ideas: 0
Solutions: 42
Registered: ‎04-28-2017

Re: SDK & TLS1.2

You could 

try {
SSLContext ctx = SSLContext.getInstance("TLSv1.2");
ctx.init(null, null, null);
SSLContext.setDefault(ctx);
} catch (Exception e) {
System.out.println(e.getMessage());
}

Or

final SSLContext ctx = SSLContext.getInstance("TLSv1.2");
ctx.init(null,null, new java.security.SecureRandom());
final SSLSocketFactory socketFactory = ctx.getSocketFactory();
HttpsURLConnection.setDefaultSSLSocketFactory(socketFactory);
Powered by NexWebSites.com -
Certified Authorize.net developers
Member
Posts: 3
Registered: ‎05-22-2017

Re: SDK & TLS1.2

That would be a solution if we don't use GAE..
With GAE the methods setFactory() and setDefaultSSLContext() are not allowed.

Posts: 492
Topics: 0
Kudos: 99
Blog Posts: 0
Ideas: 0
Solutions: 42
Registered: ‎04-28-2017

Re: SDK & TLS1.2

On GAE you could try something like:

 

exec "${RUN_JAVA}" "${SCRIPT_NAME}" \
    -Ddeployment.security.TLSv1.1=false -Ddeployment.security.TLSv1.2=true -ea -cp "${JAR_FILE}" \
    com.google.appengine.tools.KickStart \
    com.google.appengine.tools.development.DevAppServerMain "$@"

 

Powered by NexWebSites.com -
Certified Authorize.net developers
Member
Posts: 3
Registered: ‎05-22-2017

Re: SDK & TLS1.2

You are basically saying to set the system properties

Ddeployment.security.TLSv1.2 to true

And

deployment.security.TLSv1.1 to false

 
That doesn't fix the issue unfortunately..