Skip to content

Commit

Permalink
small fixes to get the hook working on android 4.4
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielAW committed May 31, 2015
1 parent db976c4 commit 73301b3
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Expand Up @@ -26,9 +26,9 @@ android {
}

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
//compile fileTree(dir: 'libs', include: ['*.jar'])
compile project(':nfcd')
compile files('libs/protobuf-java-2.6.1.jar')
compile 'com.android.support:support-v4:22.0.0'
compile files('libs/XposedBridgeApi-20150213.jar')
provided files('libs/XposedBridgeApi-20150213.jar')
}
2 changes: 1 addition & 1 deletion app/src/main/AndroidManifest.xml
Expand Up @@ -33,7 +33,7 @@
android:value="Modules for NFCGate code hooks" />
<meta-data
android:name="xposedminversion"
android:value="58" />
android:value="54" />

<activity
android:name=".gui.MainActivity"
Expand Down
2 changes: 1 addition & 1 deletion nfcd/src/main/jni/vendor/hook.cpp
Expand Up @@ -235,7 +235,7 @@ uint32_t do_hook(const char *module_path, uint32_t hook_func, const char *symbol
LOGD("[+] got entry addr: 0x%x", entry_addr);
LOGD("[+] original addr: 0x%x", original_addr);

uint32_t page_size = getpagesize();
uint32_t page_size = sysconf(_SC_PAGESIZE);
uint32_t entry_page_start = PAGE_START(entry_addr, page_size);
LOGD("[+] page size: 0x%x", page_size);
LOGD("[+] entry page start: 0x%x", entry_page_start);
Expand Down

0 comments on commit 73301b3

Please sign in to comment.