Skip to content

Conversation

@0xBl4nk
Copy link

@0xBl4nk 0xBl4nk commented Oct 21, 2025

Adds support for using bundle identifiers (e.g., com.apple.Preferences) in addition to process names when attaching to running processes.

Previously, objection only supported process names or PIDs when attaching. Using a bundle identifier would result in a ProcessNotFoundError because get_process() only matches against process names.

This change implements a fallback mechanism that:

  1. First tries the existing get_process() with the provided name
  2. If that fails, enumerates all running applications
  3. Matches the bundle identifier to find the correct application
  4. Maps the application name to its running process
  5. Returns the PID for attachment

This makes the attach workflow more user-friendly by accepting the same bundle identifier format used by frida-ps and other tools, eliminating the need to manually look up process names.

Fixes #401
Fixes #445

Tested-on:

  • Frida 17.0.7
  • iOS 16.7.10 (jailbroken device)
  • Multiple iOS applications with bundle identifiers

@0xBl4nk 0xBl4nk force-pushed the fix/process-detection-bundle-identifier branch from 7bfd21c to 00c208a Compare October 21, 2025 20:03
Adds support for using bundle identifiers (e.g., com.apple.Preferences)
in addition to process names when attaching to running processes.

Previously, objection only supported process names or PIDs when
attaching. Using a bundle identifier would result in a
ProcessNotFoundError because get_process() only matches against
process names.

This change implements a fallback mechanism that:
1. First tries the existing get_process() with the provided name
2. If that fails, enumerates all running applications
3. Matches the bundle identifier to find the correct application
4. Maps the application name to its running process
5. Returns the PID for attachment

This makes the attach workflow more user-friendly by accepting
the same bundle identifier format used by frida-ps and other
tools, eliminating the need to manually look up process names.

Fixes sensepost#401
Fixes sensepost#445

Tested-on:
- Frida 17.0.7
- iOS 17.x (jailbroken device)
- Multiple iOS applications with bundle identifiers
@0xBl4nk 0xBl4nk force-pushed the fix/process-detection-bundle-identifier branch from 00c208a to 5edf99e Compare October 21, 2025 20:16
@IPMegladon
Copy link
Collaborator

Thanks, though I have also implemented this in #743 already, similar to how frida-tools does it. Though can't remember if I tested that on iOS yet - that's also why its not merged yet.

@0xBl4nk
Copy link
Author

0xBl4nk commented Oct 27, 2025

Thanks, though I have also implemented this in #743 already, similar to how frida-tools does it. Though can't remember if I tested that on iOS yet - that's also why its not merged yet.

Thanks for letting me know! I implemented this because I was working with objection on iOS and noticed that the -n flag wasn't available for bundle identifiers. I needed this functionality for my workflow, so I added it and figured it would be useful to contribute back. I didn't realize #743 already addressed this - feel free to close this PR if that implementation is more complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] Explore crashing apps when launching using bundle ID on iOS [bug] Only name works, but not identifier of app to attach to process

2 participants