Last active
October 9, 2016 15:36
-
-
Save dweinstein/ece2110f51bcdf9a331d98c0bb1ca2cd to your computer and use it in GitHub Desktop.
Revisions
-
dweinstein revised this gist
Oct 9, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ The idea here is to organize multiple agent scripts into modules that can be combined into an aggregated agent. frida agents generally live under e.g., an `./lib/agents` directory in a top level project. # TODO -
dweinstein revised this gist
Oct 9, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -13,6 +13,6 @@ function enable (opts) { } /// only enable if we're using Frida version 8.0.0... function test (opts) { return Frida.version === '8.0.0' } -
dweinstein revised this gist
Oct 9, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ module.exports = { enable: enable, test: test, // tests for whether our agent should be enabled description: 'This script will dump the methods of the class name passed in' } function enable (opts) { -
dweinstein revised this gist
Oct 9, 2016 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -2,6 +2,8 @@ The idea here is to organize multiple agent scripts into modules that can be combined into an aggregated agent. frida agents will live under e.g., an `./lib/agents` directory. # TODO For each agent script we need a top level runner and then we use [`frida-compile`](https://github.com/frida/frida-compile) to build into a single agent script that we can load. -
dweinstein revised this gist
Oct 9, 2016 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -17,5 +17,5 @@ function enable (opts) { /// the test will be called to make sure we should enable the agent. function test (opts) { return ObjC.available && typeof opts.agent1.className !== 'undefined' } 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 charactersOriginal file line number Diff line number Diff line change @@ -14,5 +14,5 @@ function enable (opts) { /// only enable if we're using Frida version 8.0.0... function test () { return Frida.version === '8.0.0' } -
dweinstein revised this gist
Oct 9, 2016 . No changes.There are no files selected for viewing
-
dweinstein revised this gist
Oct 9, 2016 . 3 changed files with 16 additions and 6 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,7 @@ # SUMMARY The idea here is to organize multiple agent scripts into modules that can be combined into an aggregated agent. # TODO For each agent script we need a top level runner and then we use [`frida-compile`](https://github.com/frida/frida-compile) to build into a single agent script that we can load. 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 charactersOriginal file line number Diff line number Diff line change @@ -3,14 +3,19 @@ module.exports = { enable: enable, test: test, // tests for whether our agent should be enabled description: 'This script will dump the methods of the class name passe in' } function enable (opts) { // pass the className via an option to the agent // in this case we assume opts holds the options for all agent scripts rather // than just this specific script this is a design decision that can be tweaked. if (opts.agent1.className) { console.log(ObjC.classes[opts.agent1.className].$methods) } } /// the test will be called to make sure we should enable the agent. function test (opts) { return ObjC.available && typeof opts.agent1.className !== 'undefined'; } 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 charactersOriginal file line number Diff line number Diff line change @@ -12,6 +12,7 @@ function enable (opts) { } } /// only enable if we're using Frida version 8.0.0... function test () { return Frida.version === '8.0.0'; } -
dweinstein created this gist
Oct 9, 2016 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,3 @@ # SUMMARY The idea here is to organize multiple agent scripts into modules that can be combined into an aggregated agent. 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,16 @@ 'use strict' module.exports = { enable: enable, test: test, // tests for whether our agent should be enabled description: 'description here' } function enable (opts) { if (option } function test () { // perform any tests to see if this module should be enabled here return ObjC.available; } 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,17 @@ 'use strict' module.exports = { enable: enable, test: test, // tests for whether our agent should be enabled description: 'description here' } function enable (opts) { if (opts.thing) { // do something different here } } function test () { return Frida.version === '8.0.0'; } 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,6 @@ module.exports = { agents: [ require('./agent1.js'), require('./agent2.js') ] }