i2d & ASN1_SEQUENCE related query in openssl 1.1.1.

2020-10-12 Thread prudvi raj
Hi, I am trying to write replacement ASN1 macros for i2d/d2i functions in openssl 1.1.1 Previously: typedef struct pkcs7_issuer_and_subject_st { X509_NAME *issuer; /* Certificate Issuer's name */ X509_NAME *subject; /* Certificate's subject name */ }

Failure of ..new() for CTX objects in openssl 1.1.1g

2020-08-24 Thread prudvi raj
Hi, we are upgrading our codebase to openssl 1.1.1g from openssl 1.0.2k Previously, all the ctx objects are allocated memory using "calloc" typedef struct CryptWrapMDContext_t { #ifdef OPENSSL EVP_MD_CTX evpMDCtx; .. struct CryptWrapMDContext_t *pNext; } Allocation : return

Does Openssl 1.1.1 Supports GHS Platforms ??

2020-09-30 Thread prudvi raj
Hi, We are upgrading openssl library of our Embedded systems(Networking) codebase which runs on multiple platforms(Linux, Qnx & GHS) , to version 1.1.1g . (currently using 1.0.2.k) With Openssl 1.1.1g ,the CHANGES doc specifies that "QNX support has been removed" , but nowhere there's a mention

"rsa->meth->rsa_sign" method in Openssl 1.1.1g

2020-07-21 Thread prudvi raj
While upgrading to openssl 1.1.1 from 1.0.2k . I came across this code snippet : if (rsa->flags & RSA_FLAG_SIGN_VER) return rsa->meth->rsa_sign (type, m, lLen, sigret, siglen, rsa); >From Docs : Enhance RSA_METHOD structure. Now there are two extra methods, rsa_sign and rsa_verify.

'OPENSSLDIR' undeclared in openssl 1.1.1g

2020-08-13 Thread prudvi raj
Hi, I couldn't find where this macro is #defined , previously in 1.0.2 it was defined in opensslconf.h . So , i am getting this error during compilation : openssl/crypto/x509/x509_def.c:17:12: error: 'OPENSSLDIR' undeclared (first use in this function) . This error is resolved if OPENSSLDIR

'in_addr_t' in openssl 1.1.1g ??

2020-08-05 Thread prudvi raj
Hi there, I got this error during compilation , in file b_addr.c : In function 'BIO_lookup_ex': /b_addr.c:748:9: error: unknown type name 'in_addr_t' I see that "in_addr_t" is defined in "netinet/in.h" & "arpa/inet.h" in toolchain (typedef uint32_t in_addr_t;). i have even tried to #include<>

Re: 'in_addr_t' in openssl 1.1.1g ??

2020-08-05 Thread prudvi raj
-ar ARFLAGS = r CC = /opt/toolchains/adtn-6/sysroots/x86_64-fslsdk-linux/usr/bin/ppce500v2-fsl-linux-gnuspe/powerpc-fsl-linux-gnuspe-gcc CFLAGS = -O3 CPPDEFINES = CPPFLAGS= CPPINCLUDES = CROSS_COMPILE = /opt/toolchains/adtn-6/sy

get data from X509_EXTENSION in openSSL 1.1.1.

2020-07-10 Thread prudvi raj
Hi All, we are upgrading our codebase to 1.1.1 from 1.0.2k.Here's a code snippet causing error : ext = X509_get_ext(X509, n); data = ext->value->data; How do i get the data value from X509_EXTENSION object. since forward declarations are not allowed (compiler error) & i couldn't find a

Re: error : unknown type name 'sa_family_t' in openssl 1.1.1g

2020-07-23 Thread prudvi raj
ons, as they > may very well have affected diverse macros. > > Cheers, > Richard > > On Thu, 23 Jul 2020 21:39:45 +0200, > prudvi raj wrote: > > Hi, > > > > We are upgrading our code base to openssl 1.1.1g from 1.0.2k. > > During Compilation i am seeing this erro

error : unknown type name 'sa_family_t' in openssl 1.1.1g

2020-07-23 Thread prudvi raj
Hi, We are upgrading our code base to openssl 1.1.1g from 1.0.2k. During Compilation i am seeing this error : In file included from /openssl/include/internal/sockets.h:67:0, from /openssl/crypto/bio/bio_local.h:11, from /openssl/crypto/bio/bss_mem.c:12:

Re: Generate opensslconf.h - openssl 1.0.2 vs openssl 1.1.1g

2020-07-22 Thread prudvi raj
as "/usr/local/ssl" , which is default . I couldn't find where this is #define 'ed. May I know , where it's defined in openssl 1.1.1g or how this error can be resolved. ? Thanks, -Prud On Fri, Jul 17, 2020 at 2:32 PM Richard Levitte wrote: > On Thu, 16 Jul 2020 22:01:5

error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before - openssl 1.1.1 compilation

2020-07-30 Thread prudvi raj
Hi, During compilation of openssl 1.1.1g , i am seeing this error : openssl/crypto/ec/ecp_nistz256_table.c:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘ecp_nistz256_precomputed’ options used : ./Configure no-threads no-dso no-shared no-zlib no-asm no-engine no-bf

Generate opensslconf.h - openssl 1.0.2 vs openssl 1.1.1g

2020-07-16 Thread prudvi raj
Hello, How do i generate "opensslconf.h" in openssl 1.1.1g? >From docs, i assume it is created after we give "./Configure gcc". I observe that "opensslconf.h" is created only on giving "make" after ./Configure... But this additionally created .d & .o files in crypto folders. For openssl1.0.2 ,

Set custom bn_mod_exp functions in openssl 1.1.1

2020-12-17 Thread prudvi raj
Hi, I need to set custom accelerated functions for bn_mod_exp methods in openssl 1.1.1, while upgrading for openssl 1.0.2. Here's the code snippet () : -- static DH_METHOD Intoto_DH_Method; static RSA_METHOD Intoto_RSA_Method; static DSA_METHOD Intoto_DSA_Method; void

Re: Set custom bn_mod_exp functions in openssl 1.1.1

2020-12-21 Thread prudvi raj
= Intoto_DSA_mod_exp; DSA_set_default_method(_DSA_Method); return; } -- Do you suggest any modifications, If any ?? Thanks, Prudvi. On Thu, Dec 17, 2020 at 4:07 PM Tomas Mraz wrote: > On Thu, 2020-12-17 at 15:16 +0530, prudvi raj wrote: > > Hi, > > > > I need to set custom acc

How to Manually allocate BIGNUM ->d and set dmax, top values to create a Result Buffer in openssl 1.1.1 ?

2020-12-22 Thread prudvi raj
Hello all, We use a hardware accelerator to calculate BIGNUM rr = a^p mod m .( bn_mod_exp). I am trying to rewrite that logic for openssl 1.1.1. Code snippet of custom bn_mod_exp function: -- if(rr->d) { OPENSSL_free(rr->d); } rr->d = ( BN_ULONG * )( malloc( m->top *

Re: How to Manually allocate BIGNUM ->d and set dmax, top values to create a Result Buffer in openssl 1.1.1 ?

2020-12-22 Thread prudvi raj
x values , ..as this ret variable isn't the part of RSA structure (yet) when the bn_mod_exp is called. Checkout this function "rsa_ossl_public_decrypt" for more details. Hope that clarifies the scenario . Please let me know if you have any questions. Thanks, Prudvi. On Tue, Dec 22, 202