expand the demo to a third topic

This commit is contained in:
JJTech0130 2023-05-02 18:36:13 -04:00
parent cc54c4b79a
commit 27528bf1da
No known key found for this signature in database
GPG key ID: 23C92EBCCF8F93D6
2 changed files with 5 additions and 1 deletions

View file

@ -156,8 +156,9 @@ def lookup(topic:str, users: list[str]):
# Hack to make sure that the requests and responses match up # Hack to make sure that the requests and responses match up
# This filter MUST contain all the topics you are looking up # This filter MUST contain all the topics you are looking up
conn.filter(['com.apple.madrid', 'com.apple.private.alloy.facetime.multi']) conn.filter(['com.apple.madrid', 'com.apple.private.alloy.facetime.multi', 'com.apple.private.alloy.multiplex1'])
import time import time
print("...waiting for queued messages... (this is a hack)")
time.sleep(5) # Let the server send us any messages it was holding time.sleep(5) # Let the server send us any messages it was holding
conn.sink() # Dump the messages conn.sink() # Dump the messages
@ -167,6 +168,8 @@ lookup("com.apple.private.alloy.facetime.multi", ["mailto:jjtech@jjtech.dev"])
lookup("com.apple.private.alloy.facetime.multi", ["mailto:user_test2@icloud.com"]) lookup("com.apple.private.alloy.facetime.multi", ["mailto:user_test2@icloud.com"])
lookup("com.apple.madrid", ["mailto:user_test2@icloud.com"]) lookup("com.apple.madrid", ["mailto:user_test2@icloud.com"])
lookup("com.apple.private.alloy.multiplex1", ["mailto:user_test2@icloud.com"])
# Save config # Save config
with open("config.json", "w") as f: with open("config.json", "w") as f:
json.dump(CONFIG, f, indent=4) json.dump(CONFIG, f, indent=4)

View file

@ -8,6 +8,7 @@ import tlslite
# setting path # setting path
sys.path.append("../") sys.path.append("../")
sys.path.append("../../")
# APNs server to proxy traffic to # APNs server to proxy traffic to
APNS_HOST = "windows.courier.push.apple.com" APNS_HOST = "windows.courier.push.apple.com"