diff --git a/README.md b/README.md
new file mode 100644
index 0000000..9365ac1
--- /dev/null
+++ b/README.md
@@ -0,0 +1,19 @@
+# nmap-webui
+A simple web interface for Nmap for network discovery and monitoring
+
+## Dependencies
+
+As most of the `nmap` features requires to be `root`, you will have to run this command to avoid the need to specify the password when the interface will invocate `nmap`.
+
+```bash
+# Authorize nmap to run as root without password
+echo "$USER ALL = NOPASSWD: $(which nmap)" | sudo tee -a /etc/sudoers.d/nmap
+```
+
+Allow web server to save scans:
+
+```bash
+mkdir scans
+chown www-data scans
+chmod 750 scans
+```
\ No newline at end of file
diff --git a/config.php b/config.php
index 9c4ffd0..f0ec42f 100644
--- a/config.php
+++ b/config.php
@@ -1,5 +1,5 @@
.detail {
+ margin-left: 0.3em;
+ text-transform: capitalize;
+}
+
+.ui.form .fields > .field {
+ width: 100%;
+}
+
+.ui.ui.form .field .fields .field:not(:only-child) .ui.checkbox {
+ margin-top: 0;
+}
+
+.ui.dropdown.label {
+ min-width: auto;
+}
+
+.ui.dropdown.label > .remove.icon {
+ right: 2.3em;
+}
+
+.toast-container .ui.header {
+ text-transform: capitalize;
+}
+
+.share-size {
+ --free-ratio: calc(var(--free) / var(--total));
+ --used-percent: calc(100% - 100% * var(--free-ratio));
+ --color: hsl(calc(120 * var(--free-ratio)) 100% 50%);
+ background-image: linear-gradient(
+ to right,
+ var(--color) var(--used-percent),
+ transparent var(--used-percent),
+ transparent
+ ) !important;
+ text-align: center !important;
+ font-size: .64285714rem !important;
+}
\ No newline at end of file
diff --git a/stylesheets/lanScan.xsl b/stylesheets/lanScan.xsl
index db939e2..4db20a3 100644
--- a/stylesheets/lanScan.xsl
+++ b/stylesheets/lanScan.xsl
@@ -5,6 +5,7 @@
version="1.1">
+
@@ -19,7 +20,7 @@
+ select="document(concat($base, 'scans/', translate($targets,'/', '!'), '.xml'))/nmaprun" />
@@ -44,25 +45,25 @@
@@ -71,13 +72,13 @@
+ class="ui sortable small striped table">
Etat |
Adresse IP |
Nom |
- Fabricant |
+ Constructeur |
Services |
|
@@ -107,20 +108,10 @@ var table = $('#scanResultsTable').DataTable({
table.order([1, 'asc']).draw()
$('.ui.dropdown').dropdown()
-
-function hostScanning(link) {
- link.getElementsByTagName('i')[0].className = 'loading spinner icon'
- $.toast({
- title : 'Scan en cours...',
- message : 'Merci de patienter',
- class : 'info',
- showIcon : 'satellite dish',
- displayTime: 0,
- closeIcon : true,
- position : 'bottom right',
- })
-}
+
+
+
@@ -184,7 +175,15 @@ function hostScanning(link) {
|
- |
+
+
+
+
+
+
+
+
+ |
scan.php?host=
diff --git a/stylesheets/services.xsl b/stylesheets/services.xsl
index a4cec9f..e94e3d4 100644
--- a/stylesheets/services.xsl
+++ b/stylesheets/services.xsl
@@ -17,6 +17,7 @@
+ dropdown button share-size
red
orange
@@ -25,10 +26,6 @@
orange
red
-
- mini dropdown button share-size
- small
-
diff --git a/stylesheets/toast.xsl b/stylesheets/toast.xsl
new file mode 100644
index 0000000..5753551
--- /dev/null
+++ b/stylesheets/toast.xsl
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
|