Skip to content

Instantly share code, notes, and snippets.

// Generates the APISIDDHASH / SAPISIDHASH token Google uses in the Authorization header of some API requests
// Usage: node google_token_hash_generator.js <TOKEN> <DOMAIN>
var TOKEN = process.argv[2]; // APISID / SAPISID token (base64)
var DOMAIN = process.argv[3]; // Domain name, including https://, without trailing slash
var $gb = function () {
function a() {
e[0] = 1732584193;
e[1] = 4023233417;

Hướng dẫn

Vào một trang video Tiktok bất kỳ, copy đoạn code phía dưới, quay lại trang xem video Tiktok rồi nhấn Ctrl + Shift + I (hoặc Command + Shift + I trên Macbook). Sau đó qua tab console, paste đoạn code vào rồi nhấn Enter, chờ tí tẹo Video sẽ bắt đầu tải.

(function () {
  const videoEl = document.querySelector('video');
  function downloadVideo(url) {
    fetch(url).then(response => {
      if (!response.ok) throw new Error(`HTTP error! Status: ${response.status}`);
      return response.blob();
@torohima
torohima / encrypt.cs
Created July 27, 2023 11:56 — forked from huoshan12345/encrypt.cs
Instagram enc_password generator in C#
// Packages need to be installed:
// Sodium.Core
// System.Security.Cryptography.Algorithms
// The values of publicKey,keyId,version are from shared_data.
// You need to call https://www.instagram.com/data/shared_data/ to get shared_data first
public static string GenerateEncPassword(string password, string publicKey, string keyId, string version)
{
var time = DateTime.UtcNow.ToTimestamp(); // Unix timestamp
var keyBytes = publicKey.HexToBytes(); // Convert a hex string to a byte array
Device OS OS version Browser Browser version GPU vendor GPU renderer
Apple iPad 5th iOS 11.0.3 Mobile Safari 11.0 Apple Inc. Apple A9 GPU
Apple iPad Air 2 iOS 8.4 Mobile Safari 8.0
Apple iPad Mini 3 iOS 8.1.2 Mobile Safari 8.0
Apple iPad Pro iOS 11.2.1 Mobile Safari 11.0 Apple Inc. Apple A9X GPU
Apple iPhone 5S iOS
@torohima
torohima / AdbCommands
Created July 21, 2021 18:01 — forked from Pulimet/AdbCommands
Adb useful commands list
adb help // List all comands
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
@torohima
torohima / download.js
Created July 19, 2021 17:06 — forked from thinhbuzz/download.js
Download all photos from facebook Page
(async () => {
function sleep(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function findToken() {
const tags = Array.from(
document.body.querySelectorAll("script:not([src])")
);
let fb_dtsg = "";
@torohima
torohima / frida_multiple_unpinning.js
Created April 9, 2021 16:48 — forked from akabe1/frida_multiple_unpinning.js
Another Android ssl certificate pinning bypass for various methods
/* Android ssl certificate pinning bypass script for various methods
by Maurizio Siddu
Run with:
frida -U -f [APP_ID] -l frida_multiple_unpinning.js --no-pause
*/
setTimeout(function() {
Java.perform(function () {
console.log('');
@torohima
torohima / keybase.md
Created September 11, 2019 13:01
mota

Keybase proof

I hereby claim:

  • I am torohima on github.
  • I am torohima (https://keybase.io/torohima) on keybase.
  • I have a public key ASAadNzW4c5rI947bjE6CtRvZM21Tg3gkKKq1dBVMLtteAo

To claim this, I am signing this object:

@torohima
torohima / get-facebook-token-console-android.js
Created January 4, 2019 13:09 — forked from dieudv/get-facebook-token-console-android.js
Press F12 -> Console and patse this code for android or for ios. (Cre: dieudv)
var email = "youremail";
var password = "yourpassword";
var BASE_URL = "https://api.facebook.com/restserver.php";
var API_SECRET = "62f8ce9f74b12f84c123cc23437a4a32";
var md5 = function(d){result = M(V(Y(X(d),8*d.length)));return result.toLowerCase()};function M(d){for(var _,m="0123456789ABCDEF",f="",r=0;r<d.length;r++)_=d.charCodeAt(r),f+=m.charAt(_>>>4&15)+m.charAt(15&_);return f}function X(d){for(var _=Array(d.length>>2),m=0;m<_.length;m++)_[m]=0;for(m=0;m<8*d.length;m+=8)_[m>>5]|=(255&d.charCodeAt(m/8))<<m%32;return _}function V(d){for(var _="",m=0;m<32*d.length;m+=8)_+=String.fromCharCode(d[m>>5]>>>m%32&255);return _}function Y(d,_){d[_>>5]|=128<<_%32,d[14+(_+64>>>9<<4)]=_;for(var m=1732584193,f=-271733879,r=-1732584194,i=271733878,n=0;n<d.length;n+=16){var h=m,t=f,g=r,e=i;f=md5_ii(f=md5_ii(f=md5_ii(f=md5_ii(f=md5_hh(f=md5_hh(f=md5_hh(f=md5_hh(f=md5_gg(f=md5_gg(f=md5_gg(f=md5_gg(f=md5_ff(f=md5_ff(f=md5_ff(f=md5_ff(f,r=md5_ff(r,i=md5_ff(i,m=md5_ff(m,f,r,i,d[n+0],7,-680876936),f,r,d[n+1],12,-389564586),m,
@torohima
torohima / token.js
Created October 15, 2018 03:26 — forked from silverwolfceh/token.js
Get Page Manager For IOS token
javascript:var uid = document.cookie.match(/c_user=(\d+)/)[1], dtsg = document.getElementsByName("fb_dtsg")[0].value, http = new XMLHttpRequest, app_id=prompt("App id", "165907476854626"), url = "//www.facebook.com/v1.0/dialog/oauth/confirm", params = "fb_dtsg=" + dtsg + "&app_id=" + app_id + "&redirect_uri=fbconnect%3A%2F%2Fsuccess&display=page&access_token=&from_post=1&return_format=access_token&domain=&sso_device=ios&__CONFIRM__=1&__user=" + uid;http.open("POST", url, !0), http.setRequestHeader("Content-type", "application/x-www-form-urlencoded"), http.onreadystatechange = function() { if (4 == http.readyState && 200 == http.status) { var a = http.responseText.match(/access_token=(.*)(?=&expires_in)/); a = a ? a[1] : "Failed to get Access token make sure you authorized Page Manager For IOS app", prompt("Token", a); }}, http.send(params);