Skip to content

Commit

Permalink
More theme changes here and there
Browse files Browse the repository at this point in the history
  • Loading branch information
Martinvlba committed Nov 20, 2020
1 parent 0969e06 commit 57d11c9
Show file tree
Hide file tree
Showing 9 changed files with 42 additions and 32 deletions.
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ android {
minSdkVersion 17
targetSdkVersion 29
//noinspection HighAppVersionCode
versionCode 004
versionName "0.0.4"
versionCode 005
versionName "0.0.5"
multiDexEnabled true
}

Expand Down
7 changes: 7 additions & 0 deletions res/layout/customcommands.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
android:scrollbars="none"
app:layout_constraintTop_toBottomOf="@+id/f_customcommands_scrollView"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintBottom_toBottomOf="parent">

<LinearLayout
Expand All @@ -52,20 +53,26 @@
android:orientation="horizontal">

<Button
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
android:id="@+id/f_customcommands_addItemButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@android:style/Holo.Light.ButtonBar"
android:text="Add" />

<Button
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
android:id="@+id/f_customcommands_deleteItemButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@android:style/Holo.Light.ButtonBar"
android:text="Delete" />

<Button
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
android:id="@+id/f_customcommands_moveItemButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand Down
3 changes: 0 additions & 3 deletions res/layout/customcommands_recyclerview_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -112,17 +112,14 @@

<Button
android:id="@+id/f_customcommands_recyclerview_btn_run"
style="@style/Widget.AppCompat.Button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_weight="0.8"
android:alpha="0.50"
android:bufferType="normal"
android:capitalize="characters"
android:fontFamily="sans-serif-condensed"
android:text="RUN"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textColor="#FFFFFF"
android:textDirection="firstStrong"
android:textSize="14sp" />
Expand Down
2 changes: 0 additions & 2 deletions res/layout/nethunter_recyclerview_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,10 @@

<Button
android:id="@+id/f_nethunter_item_run_btn"
style="@style/Widget.AppCompat.Button"
android:layout_width="77dp"
android:fontFamily="sans-serif-condensed"
android:layout_height="wrap_content"
android:text="RUN"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textColor="#FFFFFF"
android:textSize="14sp" />

Expand Down
6 changes: 3 additions & 3 deletions res/layout/searchsploit_item.xml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
android:layout_alignParentStart="true" />

<Button
android:textSize="10dp"
android:id="@+id/viewSource"
style="?android:attr/buttonStyleSmall"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/searchsploit_sendhid_button"
Expand Down Expand Up @@ -118,8 +118,8 @@
android:layout_alignStart="@+id/author" />

<Button
android:textSize="10dp"
android:id="@+id/openWeb"
style="?android:attr/buttonStyleSmall"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/viewSource"
Expand All @@ -129,8 +129,8 @@
android:textColor="@android:color/holo_blue_dark" />

<Button
android:textSize="10dp"
android:id="@+id/searchsploit_sendhid_button"
style="?android:attr/buttonStyleSmall"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignStart="@+id/viewSource"
Expand Down
2 changes: 1 addition & 1 deletion res/layout/sidenav_header.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="114dp"
android:background="@drawable/cropbg"
android:background="@drawable/nh_cropbg"
android:orientation="horizontal">

<com.google.android.material.floatingactionbutton.FloatingActionButton xmlns:app="http://schemas.android.com/apk/res-auto"
Expand Down
2 changes: 2 additions & 0 deletions res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,9 @@
<item>wlan0</item>
<item>wlan1</item>
<item>wlan2</item>
<item>wlan3</item>
<item>eth0</item>
<item>eth1</item>
<item>rndis0</item>
<item>usb0</item>
</string-array>
Expand Down
18 changes: 16 additions & 2 deletions res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,34 @@
<item name="colorPrimary">#AE1E1E1E</item>
<item name="colorPrimaryDark">@color/material_blue_grey_950</item>
<item name="colorAccent">#B5B5B5</item>

<!-- other styles/themes -->
<item name="dialogTheme">@style/DialogStyle2</item>
<item name="drawerArrowStyle">@style/DrawerArrowStyle</item>

<!-- button styles -->
<item name="materialButtonStyle">@style/kekbutton</item>
<item name="buttonStyle">@style/kekbutton</item>

<!-- text colors/colours -->
<item name="android:textColorLink">#476CCD</item>
<item name="android:textColor">#E5E8ED</item>

<!-- text size -->
<item name="android:textSize">14dp</item>

<!-- Button background colors/colours -->
<item name="colorBackgroundFloating">#1C1C1C</item>

<!-- Button text colors/colours -->
<item name="android:negativeButtonText">#FFFFFF</item>

<!-- Button styles-->
<item name="buttonBarNegativeButtonStyle">@style/NegativeButtonStyle</item>
<item name="buttonBarPositiveButtonStyle">@style/PositiveButtonStyle</item>
<item name="buttonBarNeutralButtonStyle">@style/NeutralButtonStyle</item>

<item name="dialogTheme">@style/DialogStyle2</item>

<!-- Main styles-->
<item name="android:windowShowWallpaper">true</item>
<item name="android:windowBackground">@color/colorBackground</item>

Expand Down
30 changes: 11 additions & 19 deletions src/com/offsec/nethunter/SQL/CustomCommandsSQL.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,29 +40,21 @@ public class CustomCommandsSQL extends SQLiteOpenHelper {
{"4", "Stop wlan0 monitor mode",
"su -c \"ifconfig wlan0 down; echo 0 > /sys/module/wlan/parameters/con_mode; ip link set wlan0 up; svc wifi enable\"; exit",
"android", "interactive", "0"},
{"5", "Start wlan1 in monitor mode",
{"5", "Start wlan0 in monitor mode (POCO F1)",
"su -c \"svc wifi disable; sleep 2; echo 4 > /sys/module/wlan/parameters/con_mode; sleep 2; killall -q -SIGSTOP lowi-server || true; ip link set wlan0 up; echo done\"; exit",
"android", "interactive", "0"},
{"6", "Stop wlan0 monitor mode (POCO F1)",
"su -c \"ip link set wlan0 down && sleep 5 && echo 0 > /sys/module/wlan/parameters/con_mode && echo done\"; exit",
"android", "interactive", "0"},
{"7", "Start wlan1 in monitor mode",
"ip link set wlan1 down && iw wlan1 set monitor control && ip link set wlan1 up;exit",
"kali", "interactive", "0"},
{"6", "Start wlan2 in monitor mode",
{"8", "Start wlan2 in monitor mode",
"ip link set wlan2 down && iw wlan2 set monitor control && ip link set wlan2 up;exit",
"kali", "interactive", "0"},
{"7", "Start beef",
"cd /usr/share/beef-xss; && ./beef; exit",
"kali", "interactive", "0"},
{"8", "Y-cable start",
"su -c \"bootkali ycable start;exit\"",
"android", "interactive", "0"},
{"9", "Y-cable stop",
"su -c \"bootkali ycable start;exit\"",
"android", "interactive", "0"},

// New way of making wlan0 mon mode (WIP)
// {"4", "Start wlan0 in monitor mode",
// "su -c \"svc wifi disable; sleep 1; echo 4 > /sys/module/wlan/parameters/con_mode; sleep 2; iwpriv wlan0 MonitorModeConf 11 40 1 111 0; iwpriv wlan0 monitor 1; killall -q -SIGSTOP lowi-server || true; ip link set wlan0 up;\";",
// "android", "interactive", "0"},
// {"5", "Stop wlan0 monitor mode",
// "su -c \"iwpriv wlan0 monitor 0; ip link set wlan0 down; sleep 1; echo 0 > /sys/module/wlan/parameters/con_mode; sleep 2; killall -q -SIGCONT lowi-server || true\";",
// "android", "interactive", "0"},
{"9", "Start beef",
"cd /usr/share/beef-xss; ./beef",
"kali", "interactive", "0"}
};

public synchronized static CustomCommandsSQL getInstance(Context context){
Expand Down

0 comments on commit 57d11c9

Please sign in to comment.