Skip to content

Commit

Permalink
Code QA
Browse files Browse the repository at this point in the history
  • Loading branch information
ajinabraham committed Dec 6, 2023
1 parent 6e03370 commit 6434d0b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
2 changes: 2 additions & 0 deletions mobsf/DynamicAnalyzer/views/android/frida_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ def spawn(self):
except frida.TimedOutError:
logger.error('Timed out while waiting for device to appear')
except (frida.ProcessNotFoundError,
frida.ProcessNotRespondingError,
frida.TransportError,
frida.InvalidOperationError):
pass
Expand Down Expand Up @@ -184,6 +185,7 @@ def session(self, pid, package):
except frida.NotSupportedError:
logger.exception('Not Supported Error')
except (frida.ProcessNotFoundError,
frida.ProcessNotRespondingError,
frida.TransportError,
frida.InvalidOperationError):
pass
Expand Down
6 changes: 4 additions & 2 deletions mobsf/DynamicAnalyzer/views/ios/frida_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ def __init__(
self.dump_file = self.ipa_dir / 'mobsf_dump_file.txt'
self.container_file = self.ipa_dir / 'mobsf_app_container_path.txt'
self.not_supported_text = (
'Failed to instrument the app with Frida.'
'This app is not supported by Frida.'
'Failed to instrument the app with Frida. '
'This app is not supported by Frida. '
'Are you able to run the app on '
'this device?')

Expand Down Expand Up @@ -178,6 +178,7 @@ def spawn(self):
logger.error(self.not_supported_text)
return
except (frida.ProcessNotFoundError,
frida.ProcessNotRespondingError,
frida.TransportError,
frida.InvalidOperationError):
pass
Expand Down Expand Up @@ -222,6 +223,7 @@ def session(self, pid, bundle_id):
except frida.NotSupportedError:
logger.error(self.not_supported_text)
except (frida.ProcessNotFoundError,
frida.ProcessNotRespondingError,
frida.TransportError,
frida.InvalidOperationError):
pass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1266,7 +1266,6 @@ <h4 class="modal-title">Run TLS/SSL Security Tests - {{ package }}</h4>
$('#frida_attach_mdl').modal('toggle');
} else if (frida_action =='get'){
var injected = document.getElementById("injected_content");
injected.innerHTML = '';
injected.innerHTML = '<pre id="injected-pre"></pre>';
document.getElementById("injected-pre").textContent = json.message;
EnlighterJS.enlight( document.getElementById('injected-pre'), {
Expand Down
2 changes: 1 addition & 1 deletion mobsf/templates/dynamic_analysis/ios/dynamic_analyzer.html
Original file line number Diff line number Diff line change
Expand Up @@ -1029,6 +1029,7 @@ <h5 class="modal-title" id="exampleModalLabel">Attach to a Running Process</h5>
print_status('Runnning application');
} else {
print_status('Failed to run the application');
Swal.fire('Failed!', escape(json.message), 'error')
}
});
return false;
Expand Down Expand Up @@ -1117,7 +1118,6 @@ <h5 class="modal-title" id="exampleModalLabel">Attach to a Running Process</h5>
$('#frida_attach_mdl').modal('toggle');
} else if (frida_action =='get'){
var injected = document.getElementById("injected_content");
injected.innerHTML = '';
injected.innerHTML = '<pre id="injected-pre"></pre>';
document.getElementById("injected-pre").textContent = json.message;
EnlighterJS.enlight( document.getElementById('injected-pre'), {
Expand Down

0 comments on commit 6434d0b

Please sign in to comment.