Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About Airtag for playing custom sounds in iOS16.5.1 #1

Open
ac0d3r opened this issue Apr 21, 2024 · 0 comments
Open

About Airtag for playing custom sounds in iOS16.5.1 #1

ac0d3r opened this issue Apr 21, 2024 · 0 comments

Comments

@ac0d3r
Copy link

ac0d3r commented Apr 21, 2024

I found that the API has been changed to +[CLDurianTask startSoundSequenceTaskWithEncodedSequence:] in iOS 16.5.1,
The Sequence parameter is NSZeroData, and the content is empty.

Untitled

Then I continued to search upwards for information about the sound* API, passing the Sequence parameter in the -[CLDurianService playSoundSequence: onTag: forClient:]:
Untitled

CLFindMyAccessorySoundSequence class information: https://developer.limneos.net/index.php?ios=15.2.1&framework=CoreLocation.framework&header=CLFindMyAccessorySoundSequence.h
Untitled

The SoundSequence is the original data:
image

I tried to change this data:

  onEnter(log, args, state) {
    log(`-[CLFindMyAccessorySoundSequence initWithType:${args[2]} encodedSequence:${args[3]}]`);
    var data = ObjC.Object(args[3]);
    log(`sound data ==> ${data}`); // [0x04, 0x01, 0x00, 0x00, 0x05, 0x02, 0x00, 0x00]

    // change it
    var bytes = [0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00];  // 2x short round of beeps
    var params_raw = Memory.alloc(bytes.length);
    params_raw.writeByteArray(bytes);
    // NSData['- initWithBytes:length:']
    args[3] = ObjC.classes.NSData.alloc().initWithBytes_length_(params_raw, bytes.length);
  },

but it still didn't seem to work, playing the same sound as before
image

@ac0d3r ac0d3r changed the title About Play Custom Sound in iOS16.5.1 About Airtag for playing custom sounds in iOS16.5.1 Apr 21, 2024
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

No branches or pull requests

1 participant