Can I use .Net (openssl.net without GUI) library in the open

Posted by xytop on 09-Sep-2014 04:40

Hi,

can I use .Net library (openssl.net without GUI) in the OpenEdge Webspeed application?

(OE 10.2B07 for windows)

Timofei

Posted by Rob Debbage on 09-Sep-2014 08:10

Hi,

Support for non-GUI clients to access .NET objects was only added in OpenEdge 11.x. You cannot access .NET objects with TTY clients, AppServer / WebSpeed Agents in OpenEdge 10.2x, only the GUI client.

Kind regards,

Rob

All Replies

Posted by Mike Fechner on 09-Sep-2014 05:06

As long as it's not .NET framework version 4.x it should work in 10.2B. .NET 4.x requires OE11

Von meinem Windows Phone gesendet

Von: xytop
Gesendet: ‎09.‎09.‎2014 11:40
An: TU.OE.Development@community.progress.com
Betreff: [Technical Users - OE Development] Can I use .Net (openssl.net without GUI) library in the openedge webspeed (OE 10.2B07 for windows)?

Thread created by xytop

Hi,

can I use .Net library (openssl.net without GUI) in the OpenEdge Webspeed application?

(OE 10.2B07 for windows)

Timofei

Stop receiving emails on this subject.

Flag this post as spam/abuse.

Posted by xytop on 09-Sep-2014 08:00

Thanks!

openssl.net - A managed OpenSSL wrapper written in C# for the 2.0 .NET Framework that exposes both the Crypto API and the SSL API. (http://openssl-net.sourceforge.net/)

simple app:

USING System.*. 
USING OpenSSL.*.
USING OpenSSL.Core.*.
USING OpenSSL.Crypto.*.

DEFINE VARIABLE key AS CLASS CryptoKey NO-UNDO.
DEFINE VARIABLE signiture   AS "System.Byte[]".

DEFINE VARIABLE isVerified  AS LOGICAL NO-UNDO INIT FALSE.

DEFINE VARIABLE VK_MAK_STR AS CHARACTER NO-UNDO.
DEFINE VARIABLE VK_MAK AS CHARACTER NO-UNDO.


ASSIGN
    VK_MAK = "nb0Yq1CIZtOgBD93m27Ozrd0QWjKFIzPMlQzW5="
    VK_MAK_STR = "1234567890123456" . 

DO ON ERROR UNDO, LEAVE:
    key = CryptoKey:FromPublicKey(OpenSSL.Core.BIO:File("C:\work\openedge\pkk_pub._key", "r"),?) NO-ERROR.

    signiture = Convert:FromBase64String(VK_MAK) NO-ERROR.

    isVerified = MessageDigestContext:Verify(MessageDigest:SHA1, NEW BIO(VK_MAK_STR), signiture, key) NO-ERROR.
END.

LOG-MANAGER:WRITE-MESSAGE(STRING(isVerified), "RESULT").

In the OE Client works fine, but when compiling in OE WEBSPEED - error: "Could not find class or interface CryptoKey. (12886) ** Could not understand line 6. (196)".

Tell me, please, this code will work in OE WEBSPEED (10.2B07 for windows)?

Posted by Rob Debbage on 09-Sep-2014 08:10

Hi,

Support for non-GUI clients to access .NET objects was only added in OpenEdge 11.x. You cannot access .NET objects with TTY clients, AppServer / WebSpeed Agents in OpenEdge 10.2x, only the GUI client.

Kind regards,

Rob

This thread is closed