add old go tooling
This commit is contained in:
15
macho-go/proto/bcell_file.proto
Normal file
15
macho-go/proto/bcell_file.proto
Normal file
@ -0,0 +1,15 @@
|
||||
syntax = "proto3";
|
||||
|
||||
option optimize_for = LITE_RUNTIME;
|
||||
option go_package = "pkg/protomodel";
|
||||
|
||||
import "config.proto";
|
||||
import "macho_info.proto";
|
||||
|
||||
package protomodel;
|
||||
|
||||
message BcellFile {
|
||||
Config bcell_config = 1;
|
||||
map<string, MachoInfo> macho_infos = 2;
|
||||
}
|
||||
|
20
macho-go/proto/config.proto
Normal file
20
macho-go/proto/config.proto
Normal file
@ -0,0 +1,20 @@
|
||||
syntax = "proto3";
|
||||
|
||||
option optimize_for = LITE_RUNTIME;
|
||||
option go_package = "pkg/protomodel";
|
||||
|
||||
package protomodel;
|
||||
|
||||
message Config {
|
||||
bool hook = 1;
|
||||
bool emulator = 2;
|
||||
bool repack = 3;
|
||||
bool debug = 4;
|
||||
bool root = 5;
|
||||
bytes cert_rsa = 6;
|
||||
string server_url = 7;
|
||||
int32 report_type = 8;
|
||||
bytes obfuscator = 9;
|
||||
string remote_config_url = 10;
|
||||
string domain_id = 11;
|
||||
}
|
34
macho-go/proto/macho_info.proto
Normal file
34
macho-go/proto/macho_info.proto
Normal file
@ -0,0 +1,34 @@
|
||||
syntax = "proto3";
|
||||
|
||||
option optimize_for = LITE_RUNTIME;
|
||||
option go_package = "pkg/protomodel";
|
||||
|
||||
package protomodel;
|
||||
|
||||
message MachoInfo {
|
||||
enum PointerSize {
|
||||
invalid = 0;
|
||||
p32 = 1;
|
||||
p64 = 2;
|
||||
}
|
||||
|
||||
message InitPointer {
|
||||
uint64 offset = 1; // offset relative to the macho header
|
||||
uint64 value = 2; // address of the init function
|
||||
}
|
||||
|
||||
// iOS library rewrite these as opcodes and dyld processes
|
||||
// message LazySymbol {
|
||||
// string name = 1;
|
||||
// int32 dylib_ordinal = 2; // could be -1 -2
|
||||
// uint32 segment = 3;
|
||||
// uint32 segment_offset = 4;
|
||||
// }
|
||||
|
||||
PointerSize pointer_size = 1;
|
||||
uint64 image_base = 2;
|
||||
repeated InitPointer init_pointers = 3;
|
||||
// saved or read from header -> dyld_info -> lazyoff
|
||||
// uint64 lazy_symbol_address = 4;
|
||||
// repeated LazySymbol lazy_symbols = 5;
|
||||
}
|
16
macho-go/proto/signed_data.proto
Normal file
16
macho-go/proto/signed_data.proto
Normal file
@ -0,0 +1,16 @@
|
||||
syntax = "proto3";
|
||||
|
||||
option optimize_for = LITE_RUNTIME;
|
||||
option go_package = "pkg/protomodel";
|
||||
|
||||
package protomodel;
|
||||
|
||||
message Block {
|
||||
int32 key = 1;
|
||||
bytes value = 2;
|
||||
}
|
||||
|
||||
message SignedData {
|
||||
repeated Block blocks = 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user