cisco/libacvp

error "Curl not linked" during runtime

Closed this issue · 2 comments

Hi..
Season's greetings..

I compiled openssl 1.1.1 and then compiled curl 7.87.0 specifying openssl as the SSL. These were successful.
Then I compiled libacvp-1.5.3 specifying

  1. SSL_DIR=/users/gautam/openssl/ (the path separator used was Linux even though the environment is Win x64)
  2. LIBCURL_DIR=/users/gautam/curl/lib (this points to the lib subdirectory)
  3. FOM_DIR and SAFEC_DIR were left empty.
  4. STATIC_BUILD=TRUE, OFFLINE_BUILD=TRUE, DISABLE_KDF=TRUE

The intent is to create an offline interface that generates the request files, and uploads the response files. The IUT is on a completely different server.
This build succeeds with minor issues that were handled.

The resulting acvp_app.exe --version shows

ACVP library version(protocol version): libacvp_oss-1.5.3(1.0)

    Runtime mode: yes
       FIPS mode: no

Compiled SSL version: OpenSSL 1.1.1q 5 Jul 2022
Linked SSL version: OpenSSL 1.1.1q 5 Jul 2022

There is no mention of the curl at this stage.

Now during a run (with LD_LIBRARY specified as required)
the output is ..

.\acvp_app.exe --verbose --hash --vector_req="\users\gautam\nist\sha3\vector_req.req"

Using the following parameters:

ACV_SERVER:     demo.acvts.nist.gov
ACV_PORT:       443
ACV_URI_PREFIX: /acvp/v1/
ACV_CA_FILE:    certs/acvp.nist.gov.crt
ACV_CERT_FILE:  C:\Users\gautam\nist\nist_cert.pem
ACV_KEY_FILE:   C:\Users\gautam\nist\my_pvt_decrypted_key.key

***ACVP [INFO][acvp_http_user_agent_handler:1438]--> Offline mode, skipping user agent...
***ACVP [STATUS][acvp_login:2723]--> Logging in...
***ACVP [ERR][acvp_send_login:655]--> Curl not linked, exiting function
***ACVP [STATUS][acvp_login:2735]--> Login Send Failed
***ACVP [ERR][acvp_run:3406]--> Failed to login with ACVP server

Could you please throw any light why this is happening ? and how to get it to recognize the linked curl.
Thanks

Hello!

In this case, you are not wanting to build an offline build for libacvp. Offline builds specifically do not link to curl; they are intended to be used with an IUT that does not have access to the internet for some reason but still uses libacvp APIs and structures for testing.

You want to create an online build and use your run command (though we usually use spaces instead of equal signs between arguments and their parameters). It will save the hash vectors to a file without running them.

Thanks,
Andrew

Thanks... everything finally fell in place and the connection is going through.
v: libacvp-1.5.3 using openssl 1.1.1i and curl 7_87_0 compiled on Microsoft Windows 11 using VS 2022 version 17.2.10 (LTS)