以下分析基于 Magisk 76ddfeb93a8b3612cd68988323f422e996751e16
由于 Magisk 更新太快了,决定弃坑,自己去看源码罢!
Zygisk 加载是通过替换 app_process ,修改 LD_PRELOAD ,再执行原 app_process 实现的。
以下分析基于 Magisk 76ddfeb93a8b3612cd68988323f422e996751e16
由于 Magisk 更新太快了,决定弃坑,自己去看源码罢!
Zygisk 加载是通过替换 app_process ,修改 LD_PRELOAD ,再执行原 app_process 实现的。
| from base64 import urlsafe_b64encode, urlsafe_b64decode | |
| from Crypto.Cipher import AES | |
| from Crypto import Random | |
| BS = 16 | |
| pad = lambda s: s + (BS - len(s) % BS) * chr(BS - len(s) % BS) | |
| unpad = lambda s: s[:-ord(s[len(s) - 1:])] | |
| base64pad = lambda s: s + '=' * (4 - len(s) % 4) |
| import Foundation | |
| enum Either<A,B> { | |
| case left(A) | |
| case right(B) | |
| } | |
| // Works only using Swift 4.1 | |
| extension Either: Codable where A: Codable, B: Codable { | |
| enum CodingKeys: CodingKey { |
| var CryptoJS = require('crypto-js') | |
| var request = require('request-promise') | |
| /* | |
| * npm install crypto-js request-promise request | |
| * node wx_t1t_hack.js | |
| */ | |
| // export function testEncription(msg, fullKey) { | |
| // var fullKey = fullKey.slice(0, 16) |
| // | |
| // LoggingPrint.swift | |
| // | |
| import Foundation | |
| /** | |
| Prints the filename, function name, line number and textual representation of `object` and a newline character into | |
| the standard output if the build setting for "Active Complilation Conditions" (SWIFT_ACTIVE_COMPILATION_CONDITIONS) defines `DEBUG`. |
| +(CGFloat)pixelToPoints:(CGFloat)px { | |
| CGFloat pointsPerInch = 72.0; // see: http://en.wikipedia.org/wiki/Point%5Fsize#Current%5FDTP%5Fpoint%5Fsystem | |
| CGFloat scale = 1; // We dont't use [[UIScreen mainScreen] scale] as we don't want the native pixel, we want pixels for UIFont - it does the retina scaling for us | |
| float pixelPerInch; // aka dpi | |
| if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) { | |
| pixelPerInch = 132 * scale; | |
| } else if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) { | |
| pixelPerInch = 163 * scale; | |
| } else { | |
| pixelPerInch = 160 * scale; |
ssh user@IP -L 32400:127.0.0.1:32400
http://127.0.0.1:32400/manage/index.html
Settings > Server > General
We'll share session notes in QQ group 367375164 5 PM on weekdays.
Schedule:
| @objc protocol Refreshable | |
| { | |
| /// The refresh control | |
| var refreshControl: UIRefreshControl? { get set } | |
| /// The table view | |
| var tableView: UITableView! { get set } | |
| /// the function to call when the user pulls down to refresh | |
| @objc func handleRefresh(_ sender: Any); |