Created
November 6, 2018 10:23
-
-
Save patcon/b7e8c20cf586db63504eabe68345be4d to your computer and use it in GitHub Desktop.
A quick little script to get the internal OAuth API token from Gitter desktop (Mac).
This file contains hidden or 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
cat query.sql | sqlite3 ~/Library/Caches/com.troupe.gitter.mac.Gitter/Cache.db | |
plutil -convert xml1 /tmp/request_object.plist | |
cat /tmp/request_object.plist | grep Bearer |
This file contains hidden or 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
SELECT Writefile('/tmp/request_object.plist', b.request_object) | |
FROM cfurl_cache_response AS r | |
INNER JOIN cfurl_cache_blob_data AS b | |
ON r.entry_id = b.entry_id | |
WHERE r.request_key LIKE '%/api/private/%' | |
LIMIT 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment