Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Regular Contributor
cmr1990
Posts: 59
Registered: ‎10-16-2013
My Device: Z10
My Carrier: vodaphone

Library to use Block Cipher functions

I want to use DES encryption and need to use : hu_DESParamsCreate() function for the same.

I'm reffering https://developer.blackberry.com/native/reference/core/crypto_libref/topic/des.html in particular.

 

I'm getting this error :

Could not find qmake configuration directoryCould not find qmake configuration fileUsing OS scope before setting MAKEFILE_GENERATORE:\bbndk\host_10_0_10_536\win32\x86\usr\bin\ntoarm-ld: o.le-v7-g/.obj/EncryptionService.o: undefined reference to symbol 'hu_GlobalCtxCreateDefault'
make[2]: Leaving directory `D:/CorebridgeWS/Encryption/arm'
E:\bbndk\host_10_0_10_536\win32\x86\usr\bin\ntoarm-ld: note: 'hu_GlobalCtxCreateDefault' is defined in DSO E:/bbndk/target_10_0_10_822/qnx6/armle-v7/lib/libhuapi.so.5 so try adding it to the linker command line
make[1]: Leaving directory `D:/CorebridgeWS/Encryption/arm'
E:/bbndk/target_10_0_10_822/qnx6/armle-v7/lib/libhuapi.so.5: could not read symbols: Invalid operation

 

i think i'm supposed to link some library for building my project, i did try adding lcrypto library, but nothing!

any suggestions?!

 

Please use plain text.
BlackBerry Development Advisor (Retired)
robbieDubya
Posts: 418
Registered: ‎07-18-2012
My Device: Q10
My Carrier: Bell Canada

Re: Library to use Block Cipher functions

Hi,

 

The crypto library is openSSL's library - not the BlackBerry/Certicom FIPS approved library.

 

When you're using the hu functions, you need to add the library huapi.

 

Thanks!

--
Rob is no longer associated with BlackBerry.
Please use plain text.
New Developer
swaroop7
Posts: 16
Registered: ‎10-23-2013
My Device: Z10
My Carrier: vodafone

Re: Library to use Block Cipher functions

Hi,


I tried using huapi but it's not working?
can you tell me exact name of library to link in .pro file?

 

Thanks.

Please use plain text.
New Developer
swaroop7
Posts: 16
Registered: ‎10-23-2013
My Device: Z10
My Carrier: vodafone

Re: Library to use Block Cipher functions

Hi,

 

I got it working by using -lhuapi in .pro file.

 

Thanks.

Please use plain text.
BlackBerry Development Advisor (Retired)
robbieDubya
Posts: 418
Registered: ‎07-18-2012
My Device: Q10
My Carrier: Bell Canada

Re: Library to use Block Cipher functions

Yep! huapi is the library name. -l means use the following library.

The LIBS variable can also be used for specifying unusual paths for libraries with -L.
--
Rob is no longer associated with BlackBerry.
Please use plain text.