Created
November 17, 2014 20:33
-
-
Save timsutton/1d6b10ced1a92bb0c252 to your computer and use it in GitHub Desktop.
open -a /Applications/Hopper\ Disassembler.app /System/Library/CoreServices/diagnostics_agent
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function methImpl_ActivityTracker__resetAutoSubmitPref { | |
r15 = rdi; | |
rax = CFNumberGetTypeID(); | |
rax = _CRCopyDiagnosticMessagesHistoryValue(@"AutoSubmitVersion", rax); | |
if (rax == 0x0) goto loc_10000db7b; | |
goto loc_10000db57; | |
loc_10000db7b: | |
rax = _CRSetDiagnosticMessagesHistoryValue(@"Canary", **kCFBooleanTrue, &var_24); | |
if (rax == 0x0) goto loc_10000de09; | |
goto loc_10000db9d; | |
loc_10000de09: | |
if (*(int8_t *)(r15 + *0x100022338) == 0x0) goto loc_10000df61; | |
goto loc_10000de1b; | |
loc_10000df61: | |
return rax; | |
loc_10000de1b: | |
rax = [r15 asl]; | |
r14 = rax; | |
loc_10000de47: | |
rax = (r12)(); | |
rax = [rax retain]; | |
rax = objc_retainAutorelease(rax); | |
rbx = rax; | |
rax = (r12)(rbx, @selector(UTF8String)); | |
asl_log(r14, 0x0, 0x5, "DEBUG: %s"); | |
rax = [rbx release]; | |
goto loc_10000df61; | |
loc_10000db9d: | |
rax = _CRAutoSubmitEnabledIsSet(); | |
if (rax != 0x0) { | |
rax = CRIsAutoSubmitEnabled(); | |
if (rax == 0x0) { | |
rax = _CRSetDiagnosticMessagesHistoryValue(@"AutoSubmit", 0x0, &var_24); | |
if (rax == 0x0) { | |
r12 = *objc_msgSend; | |
rax = [r15 asl]; | |
r14 = rax; | |
rax = [NSString stringWithFormat:@"Error while clearing the global AutoSubmit preference"]; | |
rax = [rax retain]; | |
rax = objc_retainAutorelease(rax); | |
rbx = rax; | |
rax = [rbx UTF8String]; | |
asl_log(r14, 0x0, 0x3, "%s"); | |
[rbx release]; | |
rax = objc_retainAutorelease(var_24); | |
rax = [rax UTF8String]; | |
rbx = rax; | |
msgtracer_log_with_keys("com.apple.crash_reporter.bear_trap", 0x5, "com.apple.message.summary", "couldn't clear the global autosubmit preference", "com.apple.message.details", rbx); | |
} | |
r14 = **kCFPreferencesCurrentUser; | |
rbx = **kCFPreferencesCurrentHost; | |
r12 = @"com.apple.SubmitDiagInfo"; | |
CFPreferencesSetValue(@"AutoSubmit", 0x0, r12, r14, rbx); | |
rax = CFPreferencesSynchronize(r12, r14, rbx); | |
if (rax == 0x0) { | |
r12 = *objc_msgSend; | |
rax = [r15 asl]; | |
r14 = rax; | |
rax = [NSString stringWithFormat:@"Error while clearing the user AutoSubmit preference"]; | |
rax = [rax retain]; | |
rax = objc_retainAutorelease(rax); | |
rbx = rax; | |
rax = [rbx UTF8String]; | |
asl_log(r14, 0x0, 0x3, "%s"); | |
[rbx release]; | |
msgtracer_log_with_keys("com.apple.crash_reporter.bear_trap", 0x5, "com.apple.message.summary", "couldn't clear the user autosubmit preference", 0x0); | |
} | |
} | |
} | |
rax = [NSNumber numberWithInt:0x4]; | |
rax = [rax retain]; | |
rbx = rax; | |
rax = _CRSetDiagnosticMessagesHistoryValue(@"AutoSubmitVersion", rbx, &var_24); | |
r14 = rax; | |
rax = [rbx release]; | |
if (r14 == 0x0) goto loc_10000de9d; | |
goto loc_10000ddc9; | |
loc_10000de9d: | |
r12 = *objc_msgSend; | |
rax = [r15 asl]; | |
r14 = rax; | |
rax = [NSString stringWithFormat:@"Error while synching the AutoSubmit key/version"]; | |
rax = [rax retain]; | |
rax = objc_retainAutorelease(rax); | |
rbx = rax; | |
rax = [rbx UTF8String]; | |
asl_log(r14, 0x0, 0x3, "%s"); | |
[rbx release]; | |
rax = objc_retainAutorelease(var_24); | |
rax = [rax UTF8String]; | |
rbx = rax; | |
rax = msgtracer_log_with_keys("com.apple.crash_reporter.bear_trap", 0x5, "com.apple.message.summary", "error while trying to set kAutoSubmitVersion", "com.apple.message.details", rbx); | |
goto loc_10000df61; | |
loc_10000ddc9: | |
if (*(int8_t *)(r15 + *0x100022338) == 0x0) goto loc_10000df61; | |
rax = [r15 asl]; | |
r14 = rax; | |
goto loc_10000de47; | |
loc_10000db57: | |
CFNumberGetValue(rbx, 0xe, &var_16); | |
rax = CFRelease(rbx); | |
if (var_16 == 0x4) goto loc_10000df61; | |
goto loc_10000db7b; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment