// // asn1_do_lock from 0x9def58 to 0x9df034 (220 bytes) // // 11 xrefs: // > asn1_template_free @ 0x9dd500 // > asn1_template_free @ 0x9dd684 // > asn1_template_free @ 0x9dd860 // > asn1_template_free @ 0x9dd990 // > ASN1_item_free @ 0x9ddb60 // > ASN1_item_free @ 0x9ddccc // > ASN1_item_ex_free @ 0x9ddea4 // > ASN1_item_ex_free @ 0x9ddfe8 // > sub_9DE2C0 @ 0x9de4dc // > ASN1_item_ex_new @ 0x9de920 // > @ 0x7858c // // This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False! // // Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings // Generated at Fri, 27 Nov 2026 12:07:19 +0000 // int __fastcall asn1_do_lock(int *a1, int a2, unsigned __int8 *a3) { int v3; // r3 bool v4; // zf int v5; // r4 _DWORD *v6; // r3 int v7; // r5 int v8; // r2 int v9; // r6 int v10; // r0 int v12; // r0 int v13; // [sp+Ch] [bp-4h] BYREF v3 = *a3; v4 = v3 == 6; if ( v3 != 6 ) v4 = v3 == 1; if ( !v4 ) return 0; v6 = *((_DWORD **)a3 + 4); if ( !v6 ) return 0; v5 = v6[1] & 1; if ( v5 ) { v7 = *a1; v8 = v6[2]; v9 = v6[3]; v10 = *a1 + v8; if ( a2 ) { if ( CRYPTO_atomic_add(v10, a2, &v13, *(_DWORD *)(v7 + v9)) < 0 ) { return -1; } else { v5 = v13; if ( !v13 ) { CRYPTO_THREAD_lock_free(*(_DWORD *)(v7 + v9)); *(_DWORD *)(v7 + v9) = 0; return v13; } } } else { v5 = 1; *(_DWORD *)(v7 + v8) = 1; v12 = CRYPTO_THREAD_lock_new(v10); *(_DWORD *)(v7 + v9) = v12; if ( !v12 ) { ERR_put_error(13, 233, 65, "crypto/asn1/tasn_utl.c", 74); return -1; } } } return v5; }
GD Web Decomp Icon

GD Web Decomp

Raw Source