How to use cryptography in OpenEdge ABL. (RSA & SHA-256)

Posted by xytop on 28-Aug-2014 08:07

Hello,

(OpenEdge 10.2B for windows)

I need to use cryptography (RSA - signature and verification, and SHA256) in the program.
OpenEdge does not support RSA, and suggest to use the library OPENSSL.NET (http://knowledgebase.progress.com/articles/Article/P176068?q=000015881).
If I use this code:
USING OpenSsl. *.
DEFINE VARIABLE rsa AS CLASS OpenSSL.Crypto.RSA NO-UNDO.

DEFINE VARIABLE TheVersion AS CHARACTER NO-UNDO.

rsa = NEW OpenSSL.Crypto.RSA ().

MESSAGE "TEST" VIEW-AS ALERT-BOX.

I receive an error: "System.Security.SecurityException: System.Security.Permissions.SecurityPermission"

Please give me examples of how to use this library in OpenEdge ABL.

Timofei

All Replies

Posted by Mike Fechner on 28-Aug-2014 08:09

Where are your OpenSSL Assemblies located? On a network folder?
 

Posted by xytop on 28-Aug-2014 08:40

On a network folder! OMG!!! Thanks!

Can you have an example of using RSA signatures or verification for ABL?

Posted by Mike Fechner on 28-Aug-2014 08:49

I can’t help you with cryptography.
 
But when you need to use (why?) Assemblies from a network folder, add/modify this in your prowin32.exe.config file under the runtime node. The file resides in %DLC%\bin
 

<runtime>

  <loadFromRemoteSources enabled="true" />

Posted by CHT on 01-Sep-2014 06:26

Mike, afaik this only work with .NET 4 thus OE 11 and higher

This thread is closed