Skip to content

Commit 4f6aa1f

Browse files
committed
changed the way we install the MSF
1 parent 5d1c130 commit 4f6aa1f

9 files changed

Lines changed: 293 additions & 181 deletions

File tree

cSploit/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
33
package="org.csploit.android"
44
android:versionCode="1"
5-
android:versionName="1.4.9" >
5+
android:versionName="1.5.0" >
66

77
<uses-sdk
88
android:minSdkVersion="9"

cSploit/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,13 @@ dependencies {
44
compile fileTree(dir: 'libs', include: '*.jar')
55
compile 'com.android.support:support-v4:19.0.+'
66
compile 'com.actionbarsherlock:actionbarsherlock:4.4.0@aar'
7-
compile group: 'org.apache.commons', name: 'commons-compress', version: '1.6'
7+
compile 'org.apache.commons:commons-compress:1.6'
88
compile 'org.apache.commons:commons-compress:1.6:sources'
99
compile 'commons-net:commons-net:3.3'
1010
compile 'junit:junit:3.8.1'
1111
compile 'joda-time:joda-time:1.6.2'
1212
compile 'com.github.zafarkhaja:java-semver:0.8.0'
13+
compile 'com.sksamuel.diff:diff:1.1.11'
1314
}
1415

1516
android {

cSploit/res/layout/preferences.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,12 @@
210210
android:summary="@string/pref_rpc_port_desc"
211211
android:title="@string/pref_rpc_port" />
212212

213+
<EditTextPreference
214+
android:defaultValue="NONE"
215+
android:key="MSF_MANIFEST_URL"
216+
android:summary="@string/pref_msf_manifest_desc"
217+
android:title="@string/pref_msf_manifest" />
218+
213219
<Preference
214220
android:key="PREF_MSF_WIPE"
215221
android:title="@string/pref_msf_delete"

cSploit/res/values-it/strings.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,4 +430,6 @@
430430
<string name="pref_updates_msf_desc">cerca aggiornamenti per il MetaSploit Framework</string>
431431
<string name="pref_updates_gems">RubyGems</string>
432432
<string name="pref_updates_gems_desc">cerca aggiornamenti per le Gemme di Ruby</string>
433+
<string name="pref_msf_manifest">Manifest personale</string>
434+
<string name="pref_msf_manifest_desc">URL di un manifest personalizzato</string>
433435
</resources>

cSploit/res/values/strings.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,4 +488,6 @@
488488
<string name="pref_updates_msf_desc">check for MSF updates</string>
489489
<string name="pref_updates_gems">RubyGems</string>
490490
<string name="pref_updates_gems_desc">check for RubyGems updates</string>
491+
<string name="pref_msf_manifest">Custom manifest</string>
492+
<string name="pref_msf_manifest_desc">custom MSF manifest URL</string>
491493
</resources>

cSploit/src/org/csploit/android/core/ArchiveMetadata.java

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
import android.content.Intent;
44

55
import com.github.zafarkhaja.semver.Version;
6+
import com.sksamuel.diffpatch.DiffMatchPatch;
7+
8+
import java.util.HashMap;
9+
import java.util.LinkedList;
610

711
/**
812
* just a simple struct to handle archives metadata
@@ -15,7 +19,6 @@ public class ArchiveMetadata {
1519
versionString,
1620
outputDir,
1721
executableOutputDir,
18-
dirToExtract,
1922
md5,
2023
sha1;
2124
public Version
@@ -27,8 +30,11 @@ public class ArchiveMetadata {
2730
public Intent
2831
contentIntent;
2932
public boolean
33+
skipRoot,
3034
fixShebang,
3135
errorOccurred;
36+
public HashMap<String, LinkedList<DiffMatchPatch.Patch>>
37+
patches;
3238

3339
public ArchiveMetadata() {
3440
reset();
@@ -37,12 +43,13 @@ public ArchiveMetadata() {
3743
public void reset() {
3844
synchronized (this) {
3945
url = name = md5 = sha1 = versionString = path =
40-
outputDir = dirToExtract = executableOutputDir = null;
46+
outputDir = executableOutputDir = null;
4147
version = null;
4248
compression = null;
4349
archiver = null;
4450
contentIntent = null;
45-
fixShebang = errorOccurred = false;
51+
fixShebang = errorOccurred = skipRoot = false;
52+
patches = null;
4653
}
4754
}
4855

0 commit comments

Comments
 (0)