Compare commits
5 Commits
v0.0.1a-td
...
6da5e1b071
Author | SHA1 | Date | |
---|---|---|---|
|
6da5e1b071 | ||
|
8c586b47c0 | ||
|
edd3314803 | ||
|
624756dec9 | ||
|
a4a4872a75 |
@@ -6,7 +6,7 @@
|
||||
- name: Extraction archive
|
||||
unarchive:
|
||||
src: /tmp/dokuwiki-stable.tgz
|
||||
dest: /var/www/html/
|
||||
dest: /var/www/html
|
||||
remote_src: yes
|
||||
|
||||
- name: stat rept
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
- name: Renommage de dokuwiki-stable
|
||||
command: mv /var/www/html/dokuwiki-2020-07-29 /var/www/html/doku
|
||||
when: not rept_stat.stat.exists
|
||||
when: rept_stat.stat.exists
|
||||
|
||||
- name: Droit root recursive
|
||||
file:
|
||||
|
61
goss/goss.yaml
Normal file
61
goss/goss.yaml
Normal file
@@ -0,0 +1,61 @@
|
||||
package:
|
||||
apache2:
|
||||
installed: true
|
||||
versions:
|
||||
- 2.4.52-1~deb11u2
|
||||
wireguard:
|
||||
installed: true
|
||||
versions:
|
||||
- 1.0.20210223-1
|
||||
port:
|
||||
tcp6:80:
|
||||
listening: true
|
||||
ip: []
|
||||
tcp:3306:
|
||||
listening: true
|
||||
ip:
|
||||
- 127.0.0.1
|
||||
service:
|
||||
apache2:
|
||||
enabled: true
|
||||
running: true
|
||||
mysql:
|
||||
enabled: true
|
||||
running: true
|
||||
ssh:
|
||||
enabled: true
|
||||
running: true
|
||||
user:
|
||||
mysql:
|
||||
exists: true
|
||||
uid: 106
|
||||
gid: 113
|
||||
groups:
|
||||
- mysql
|
||||
home: /nonexistent
|
||||
shell: /bin/false
|
||||
group:
|
||||
mysql:
|
||||
exists: true
|
||||
gid: 113
|
||||
ssh:
|
||||
exists: true
|
||||
gid: 111
|
||||
process:
|
||||
apache2:
|
||||
running: true
|
||||
http:
|
||||
http://onfarbo42/adminer.php:
|
||||
status: 200
|
||||
allow-insecure: false
|
||||
no-follow-redirects: false
|
||||
timeout: 5000
|
||||
body:
|
||||
- Adminer
|
||||
http://onfarbo42/doku/doku.php:
|
||||
status: 200
|
||||
allow-insecure: false
|
||||
no-follow-redirects: false
|
||||
timeout: 5000
|
||||
body:
|
||||
- MISSION
|
75
nmap/scan
Normal file
75
nmap/scan
Normal file
@@ -0,0 +1,75 @@
|
||||
#Scan carte en pont : 192.168.0.45
|
||||
|
||||
Starting Nmap 7.80 ( https://nmap.org ) at 2022-02-10 14:52 CET
|
||||
Nmap scan report for 192.168.0.45
|
||||
Host is up (0.00027s latency).
|
||||
Not shown: 989 filtered ports
|
||||
PORT STATE SERVICE VERSION
|
||||
#DNS port 53 tcp
|
||||
53/tcp open domain?
|
||||
88/tcp open kerberos-sec Microsoft Windows Kerberos (server time: 2022-02-10 13:52:59Z)
|
||||
#Mappeur MSRCP port 135 tcp
|
||||
135/tcp open msrpc Microsoft Windows RPC
|
||||
#Netbios port 139 tcp
|
||||
139/tcp open netbios-ssn Microsoft Windows netbios-ssn
|
||||
#LDAP port 389 en tcp
|
||||
389/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: onfdc.lan, Site: Default-First-Site-Name)
|
||||
#SMB port 445 tcp
|
||||
445/tcp open microsoft-ds Microsoft Windows Server 2008 R2 - 2012 microsoft-ds (workgroup: ONFDC0)
|
||||
#Test intrusion LDAP port 464 tcp
|
||||
464/tcp open kpasswd5?
|
||||
#Testing MSRCP port 593 tcp
|
||||
593/tcp open ncacn_http Microsoft Windows RPC over HTTP 1.0
|
||||
#tcpwrapped port 636 tcp
|
||||
636/tcp open tcpwrapped
|
||||
#LDAP port 3268 tcp
|
||||
3268/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: onfdc.lan, Site: Default-First-Site-Name)
|
||||
#tcpwrapped port 3269 tcp
|
||||
3269/tcp open tcpwrapped
|
||||
1 service unrecognized despite returning data. If you know the service/version, please submit the following fingerprint at https://nmap.org/cgi-bin/submit.cgi?new-service :
|
||||
SF-Port53-TCP:V=7.80%I=7%D=2/10%Time=620518C2%P=x86_64-pc-linux-gnu%r(DNSV
|
||||
SF:ersionBindReqTCP,20,"\0\x1e\0\x06\x81\x04\0\x01\0\0\0\0\0\0\x07version\
|
||||
SF:x04bind\0\0\x10\0\x03");
|
||||
MAC Address: 08:00:27:29:E0:6E (Oracle VirtualBox virtual NIC) #Adresse MAC
|
||||
Service Info: Host: ONFDC; OS: Windows; CPE: cpe:/o:microsoft:windows #Systeme info
|
||||
|
||||
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
|
||||
Nmap done: 1 IP address (1 host up) scanned in 147.14 seconds #Durée scan 147.14 sec
|
||||
|
||||
#Scan carte interne : 192.168.2.1
|
||||
|
||||
Starting Nmap 7.80 ( https://nmap.org ) at 2022-02-10 15:05 CET
|
||||
Nmap scan report for 192.168.2.3
|
||||
Host is up (0.0000090s latency).
|
||||
Not shown: 999 closed ports
|
||||
PORT STATE SERVICE VERSION
|
||||
22/tcp open ssh OpenSSH 8.4p1 Debian 5 (protocol 2.0)
|
||||
Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel
|
||||
|
||||
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
|
||||
Nmap done: 1 IP address (1 host up) scanned in 13.48 seconds
|
||||
Starting Nmap 7.80 ( https://nmap.org ) at 2022-02-10 15:05 CET
|
||||
Nmap scan report for 192.168.2.1
|
||||
Host is up (0.00044s latency).
|
||||
Not shown: 989 filtered ports
|
||||
PORT STATE SERVICE VERSION
|
||||
53/tcp open domain?
|
||||
88/tcp open kerberos-sec Microsoft Windows Kerberos (server time: 2022-02-10 14:06:14Z)
|
||||
135/tcp open msrpc Microsoft Windows RPC
|
||||
139/tcp open netbios-ssn Microsoft Windows netbios-ssn
|
||||
389/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: onfdc.lan, Site: Default-First-Site-Name)
|
||||
445/tcp open microsoft-ds Microsoft Windows Server 2008 R2 - 2012 microsoft-ds (workgroup: ONFDC0)
|
||||
464/tcp open kpasswd5?
|
||||
593/tcp open ncacn_http Microsoft Windows RPC over HTTP 1.0
|
||||
636/tcp open tcpwrapped
|
||||
3268/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: onfdc.lan, Site: Default-First-Site-Name)
|
||||
3269/tcp open tcpwrapped
|
||||
1 service unrecognized despite returning data. If you know the service/version, please submit the following fingerprint at https://nmap.org/cgi-bin/submit.cgi?new-service :
|
||||
SF-Port53-TCP:V=7.80%I=7%D=2/10%Time=62051BDC%P=x86_64-pc-linux-gnu%r(DNSV
|
||||
SF:ersionBindReqTCP,20,"\0\x1e\0\x06\x81\x04\0\x01\0\0\0\0\0\0\x07version\
|
||||
SF:x04bind\0\0\x10\0\x03");
|
||||
MAC Address: 08:00:27:D2:86:46 (Oracle VirtualBox virtual NIC)
|
||||
Service Info: Host: ONFDC; OS: Windows; CPE: cpe:/o:microsoft:windows
|
||||
|
||||
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
|
||||
Nmap done: 1 IP address (1 host up) scanned in 159.90 seconds
|
79
wireguard/android.sh
Normal file
79
wireguard/android.sh
Normal file
@@ -0,0 +1,79 @@
|
||||
#!/bin/bash
|
||||
set -u
|
||||
set -e
|
||||
|
||||
AddressAwg=10.0.0.1/32 # Adresse VPN Wireguard extremite A
|
||||
EndpointA=10.121.38.68 # Adresse extremite A
|
||||
PortA=51820 # Port ecoute extremite A
|
||||
AddressBwg=10.0.0.2/32 # Adresse VPN Wireguard extremite B
|
||||
EndpointB=192.168.1.82 # Adresse extremite B
|
||||
PortB=51820 # Port ecoute extremite B
|
||||
AddressCwg=10.0.0.3/32
|
||||
EndpointC=x.y.z.t
|
||||
PortC=51820
|
||||
|
||||
umask 077 ;
|
||||
wg genkey > endpoint-a.key
|
||||
wg pubkey < endpoint-a.key > endpoint-a.pub
|
||||
|
||||
wg genkey > endpoint-b.key
|
||||
wg pubkey < endpoint-b.key > endpoint-b.pub
|
||||
|
||||
wg genkey > endpoint-c.key
|
||||
wg pubkey < endpoint-c.key > endpoint-c.pub
|
||||
|
||||
PKA=$(cat endpoint-a.key)
|
||||
pKA=$(cat endpoint-a.pub)
|
||||
PKB=$(cat endpoint-b.key)
|
||||
pKB=$(cat endpoint-b.pub)
|
||||
PKC=$(cat endpoint-c.key)
|
||||
pKC=$(cat endpoint-c.pub)
|
||||
|
||||
cat <<FINI > wg0-a.conf
|
||||
# local settings for Endpoint A
|
||||
[Interface]
|
||||
PrivateKey = $PKA
|
||||
Address = $AddressAwg
|
||||
ListenPort = $PortA
|
||||
|
||||
# remote settings for Endpoint B
|
||||
[Peer]
|
||||
PublicKey = $pKB
|
||||
#Endpoint = ${EndpointB}:$PortB
|
||||
AllowedIPs = $AddressBwg
|
||||
|
||||
# remote settings for Endpoint C
|
||||
[Peer]
|
||||
PublicKey = $pKC
|
||||
#EndPoint = ${EndpointC}:$PortC
|
||||
AllowedIPs = $AddressCwg
|
||||
FINI
|
||||
|
||||
|
||||
cat <<FINI > wg0-b.conf
|
||||
# local settings for Endpoint B
|
||||
[Interface]
|
||||
PrivateKey = $PKB
|
||||
Address = $AddressBwg
|
||||
ListenPort = $PortB
|
||||
|
||||
# remote settings for Endpoint A
|
||||
[Peer]
|
||||
PublicKey = $pKA
|
||||
Endpoint = ${EndpointA}:$PortA
|
||||
AllowedIPs = $AddressAwg
|
||||
FINI
|
||||
|
||||
cat <<FINI > wg0-c.conf
|
||||
# local settings for Endpoint C
|
||||
[Interface]
|
||||
PrivateKey = $PKC
|
||||
Address = $AddressCwg
|
||||
ListenPort = $PortC
|
||||
|
||||
# remote settings for Endpoint A
|
||||
[Peer]
|
||||
PublicKey = $pKA
|
||||
Endpoint = ${EndpointA}:$PortA
|
||||
AllowedIPs = $AddressAwg
|
||||
FINI
|
15
wireguard/wg0-b.conf
Normal file
15
wireguard/wg0-b.conf
Normal file
@@ -0,0 +1,15 @@
|
||||
# local settings for Endpoint B
|
||||
[Interface]
|
||||
PrivateKey = oMcR7DZkrkUumSdvGgC3F/uuLVYICP8kTF/6BdNsFGU=
|
||||
Address = 10.0.0.2/32
|
||||
ListenPort = 51820
|
||||
|
||||
# IP forwarding
|
||||
PreUp = sysctl -w net.ipv4.ip_forward=1
|
||||
|
||||
# remote settings for Endpoint A
|
||||
[Peer]
|
||||
PublicKey = ihizRzwgz/HEF8QHNPRYa7LYB/HTtnwWZlHltI0ZdDc=
|
||||
Endpoint = 192.168.0.51:51820
|
||||
AllowedIPs = 10.0.0.1/32, 192.168.1.0/24
|
||||
|
11
wireguard/wg0.conf
Normal file
11
wireguard/wg0.conf
Normal file
@@ -0,0 +1,11 @@
|
||||
# local settings for Endpoint A
|
||||
[Interface]
|
||||
PrivateKey = kBAtNXmiZU6jVUeAKKoooTd8q5rN7lXpJJLVlEgSlWQ=
|
||||
Address = 10.0.0.1/32
|
||||
ListenPort = 51820
|
||||
|
||||
# remote settings for Endpoint B
|
||||
[Peer]
|
||||
PublicKey = NEWioueQlPkKT4zOoIhmiQi30lV1aJ3gnG69m4T4Ezg=
|
||||
#Endpoint = 192.168.1.82:51820
|
||||
AllowedIPs = 10.0.0.2/32
|
Reference in New Issue
Block a user