BrettMayson / HEMTT

Build System for Arma 3
https://brettmayson.github.io/HEMTT
GNU General Public License v2.0
109 stars 40 forks source link

Linux keygen or signing broken #278

Closed jonpas closed 1 year ago

jonpas commented 4 years ago

HEMTT Version: 0.7.4 Project: https://github.com/Theseus-Aegis/Mods

Description:

Key generation or signing is broken on Linux - generated key and sign combination fails check (as well as -checkSignatures).

Steps to reproduce:

Additional information:

/

HEMTT Output:

/

BrettMayson commented 4 years ago

Are you able to provide any more details? There is nothing in pbo-rs or bisign that changes based on platform. At first thought this could really only be explained by a bug in openssl-rs, which I find highly unlikely.

jonpas commented 4 years ago

I didn't have a chance to debug this yet. I can provide keys/signatures of same content/mod for both platforms if that could help.

jonpas commented 4 years ago

Linux (fail)

Self-compiled HEMTT 0.8.0-2cf6fb7-debug.

[jonpas@loki] $ ./hemttdev --version
HEMTT 0.8.0-2cf6fb7-debug
[jonpas@loki] $ ./hemttdev build main --release -f --force-release                          (master) ~/D/W/A/M/T
HEMTT 0.8.0-2cf6fb7-debug
Environment: dev

♻️ Clean          [00:00:00] [##############################] [1|1]
🗑️ Clear       
🔍 Checks         [00:00:00] [##############################] [1|1]
🚧 Prebuild       [00:00:00] [##############################] [1|1]
📝 Build          [00:00:00] [##############################] [1|1]
⭐ Release     
⭐ Sign        
ReleaseBuild `@zip TheseusServices_1.13.0.21`
Archiving TheseusServices_1.13.0.21.zip

-checkSignatures:

 3:18:41 Signature E:\Arma 3\Mods\TheseusServices\releases\1.13.0.21\@theseus_services\addons\tacs_main.pbo is wrong. Error 0x22. Test FAILED!
 3:18:41 Warning Message: Signature E:\Arma 3\Mods\TheseusServices\releases\1.13.0.21\@theseus_services\addons\tacs_main.pbo is wrong. Error 0x22. Test FAILED!

TheseusServices-debug-linux.zip


Windows (success)

AppVeyor-compiled HEMTT 0.8.0-40ebc7e99a56333dd2fdf5f22c9ab65fea10f2ba-40ebc7e.

P:\x\tacs>hemtt.exe --version
HEMTT 0.8.0-40ebc7e99a56333dd2fdf5f22c9ab65fea10f2ba-40ebc7e

P:\x\tacs>hemtt.exe build main --release -f --force-release
HEMTT 0.8.0-40ebc7e99a56333dd2fdf5f22c9ab65fea10f2ba-40ebc7e
Environment: dev

Clean          [00:00:00] [##############################] [1|1]
Clear
Checks         [00:00:00] [##############################] [1|1]
Prebuild       [00:00:00] [##############################] [1|1]
Build          [00:00:00] [##############################] [1|1]
Release
Sign
ReleaseBuild `@zip TheseusServices_1.13.0.21`
Archiving TheseusServices_1.13.0.21.zip

-checkSignatures:

 3:05:51 Signature tests for p:\x\tacs\releases\1.13.0.21\@theseus_services\addons\tacs_main.pbo PASSED!

TheseusServices-debug-windows.zip

BrettMayson commented 4 years ago

A fix will need to be put in https://github.com/synixebrett/bisign

I am not sure what the could be causing this, as nothing is OS dependent in HEMTT or bisign. File order maybe?

jonpas commented 4 years ago

Generated a keypair and signed a PBO with https://github.com/synixebrett/bisign on both platforms. They both pass -checkSignatures, so the bisign library appears to work.

Could also not reproduce with CBA, but I can reproduce with Theseus Services. I don't see any difference in HEMTT configuration.

Using d828af84613f6725732a4c42c8b4611ae2a0cf81 now.

BrettMayson commented 4 years ago

Huh

jonpas commented 4 years ago

Alright, so now I tried a Theseus Services PBO and it's failing with https://github.com/synixebrett/bisign on both platform builds. At this point I am thinking it has something to do with OpenSSL version.

BrettMayson commented 1 year ago

Closing, should be fixed with 0,10. I think this was even fixed? I can't remember now

jonpas commented 1 year ago

It may have been, but technically 0.8.0 was never released. :P