Commit 79d3a04c authored by Daniel Wolf's avatar Daniel Wolf
Browse files

The query log detail now shows the connection type (DoT, DoH)

Implements #49
parent a9cec080
Pipeline #3672 passed with stage
in 42 seconds
......@@ -68,10 +68,15 @@ class QueryLogDetailFragment : Fragment() {
}
longName.text = query.name
type.text = query.type.name
protocol.text = when {
query.askedServer == null -> ""
query.askedServer!!.startsWith("https") -> getString(R.string.fragment_querydetail_mode_doh)
else -> getString(R.string.fragment_querydetail_mode_dot)
}
if(query.fromCache) {
resolvedBy.text = "Cache"
} else {
resolvedBy.text = query.askedServer ?: "-"
resolvedBy.text = query.askedServer?.replace("tls::", "")?.replace("https::", "") ?: "-"
}
}
}
......
<vector android:autoMirrored="true" android:height="24dp"
android:viewportHeight="512" android:viewportWidth="448"
android:width="21dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="?android:attr/textColor" android:pathData="M400,224h-24v-72C376,68.2 307.8,0 224,0S72,68.2 72,152v72L48,224c-26.5,0 -48,21.5 -48,48v192c0,26.5 21.5,48 48,48h352c26.5,0 48,-21.5 48,-48L448,272c0,-26.5 -21.5,-48 -48,-48zM296,224L152,224v-72c0,-39.7 32.3,-72 72,-72s72,32.3 72,72v72z"/>
</vector>
......@@ -56,6 +56,28 @@
android:layout_height="wrap_content"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:orientation="vertical"
android:layout_marginTop="24dp"
android:layout_height="wrap_content">
<TextView
android:layout_width="wrap_content"
android:layout_gravity="center"
android:textStyle="italic"
android:text="Protocol"
android:layout_height="wrap_content"/>
<TextView
android:layout_width="wrap_content"
android:textSize="18sp"
android:id="@+id/protocol"
android:drawablePadding="8dp"
android:drawableStart="@drawable/ic_lock_white"
android:layout_height="wrap_content"/>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:orientation="vertical"
......
......@@ -6,5 +6,6 @@
<item>Added this dialog to highlight changes</item>
<item>The query export setting now shows a dialog indicating whether it is loading</item>
<item>Fixed the server import not working on OS versions below Android 7</item>
<item>The query log now shows the protocol used to send the query</item>
</string-array>
</resources>
\ No newline at end of file
......@@ -23,6 +23,9 @@
<string name="quicksettings_stop_text">Stop Nebulo</string>
<string name="quicksettings_start_text">Start Nebulo</string>
<string name="fragment_querydetail_mode_dot">Dns-over-TLS</string>
<string name="fragment_querydetail_mode_doh">Dns-over-HTTPS</string>
<string-array name="theme">
<item>Mono</item>
<item>Dark</item>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment