Skip to content

Commit

Permalink
Fix Arch Linux crash on app selection
Browse files Browse the repository at this point in the history
  • Loading branch information
Dadoum committed Oct 20, 2023
1 parent 98cadf5 commit 2437b59
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 9 deletions.
5 changes: 1 addition & 4 deletions source/cms/cms_dec.d
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,8 @@ import botan.asn1.ber_dec;
import botan.asn1.oids;
import botan.codec.pem;

static this() {
OIDS.setDefaults();
}

ubyte[] dataFromCMS(DataSource source) {
OIDS.setDefaults();
if (!maybeBER(source) || PEM.matches(source)) {
source = cast(DataSource) DataSourceMemory(PEM.decodeCheckLabel(source, "PKCS7"));
}
Expand Down
9 changes: 4 additions & 5 deletions source/sideload/macho.d
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,6 @@ version (BigEndian) {
static assert(false, "Big endian systems are not supported");
}

static this() {
OIDS.setDefaults();
}

/// Will only parse little-endian on little-endian
/// I have code which is more versatile, but since it's useless (almost everything is little-endian now),
/// and is way more complex I won't put it here for now.
Expand Down Expand Up @@ -770,7 +766,10 @@ class SignatureBlob: Blob {
this.hashers = hashers;
}

ref DEREncoder encodeBlob(return ref DEREncoder der, ubyte[][] codeDirectories) { // made to match as closely as possible zsign
ref DEREncoder encodeBlob(return ref DEREncoder der, ubyte[][] codeDirectories) {
// made to match as closely as possible zsign
OIDS.setDefaults();

auto rng = identity.rng;
PKSigner signer = PKSigner(identity.privateKey, "EMSA3(SHA-256)");

Expand Down

0 comments on commit 2437b59

Please sign in to comment.