DSA test fails in Fedora
I am trying to package HsOpenSSL-0.11.4.16 for Fedora, and enabled the testsuite:
Test suite test-dsa: RUNNING...
test-dsa: Assertion failed: generateParameters
(105,7434410770759874867539421675728577177024889699586189000788950934679315164676852047058354758883833299702695428196962057871264685291775577130504050839126673,1138656671590261728308283492178581223478058193247,5154978420348751798752390524304908179080782918903280816528537868887210221705817467399501053627846983235883800157945206652168013881208773209963452245182466) /= (69,11801791923200348410254417999138025523688433823235186495193414015297372351970233788978403842874988181002562582393800219774637796928688786373367784768159739,787927147523201408713650723533345770485948819377,9522600377153181848618004367960701316347048040421430378460740592438287767686975050042906583901493638777787687336097382496338752756798974657424239592200615)
Test suite test-dsa: FAIL
https://koji.fedoraproject.org/koji/taskinfo?taskID=46248137
This is with openssl-1.1.1g.
Unfortunately, I can't reproduce it (do not have a Fedora). On macOS with openssl updated to version 1.1.1g tests work fine.
Same result with HsOpenSSL-0.11.4.18. What can I do to help debug this?
I think I can reproduce on Fedora 30, 31, 32 and Rawhide:
eg in docker run -it --rm fedora if you execute:
dnf install cabal-install ghc-devel ghc-network-devel openssl-devel
cabal update
cabal unpack HsOpenSSL
cd HsOpenSSL-*
cabal test
Anyway I went ahead with the Fedora Package - and just disabled the testsuite. Though the failure seems a bit concerning even if it is Fedora specific. I wonder if some Fedora patch is causing this.
For some reason I haven't received your previous reply.
I rewrote test-dsa in C. Try to compile it under Fedora. If it will print anything then there's some error in Fedora OpenSSL. If not then there's something strange happening in HsOpenSSL/GHC https://gist.github.com/vshabanov/bbab2052343da8731c45c7460cbfa567
Sorry I think I missed yours too, oops ;-( Okay I will try to look at this soon.
This appears (long) fixed, thank you very much - finally got back to it in view of #88