---
# System prepended metadata

title: TP 1 Security Architectures

---

# TP 1 Security Architectures

## Exercises

- Host IP address: `10.0.2.2/24`
- VM IP address: `10.0.2.15/24`

- Change the IP address:

```bash
ip addr del 10.0.2.15/24 dev enp0s3
ip addr add 10.0.2.16/24 dev enp0s3
```

- Change the MAC address:

```bash
ip link set dev enp0s3 down
ip link set dev enp0s3 address 80:00:27:64:2b
ip link set dev enp0s3 up
```

- Create two users' groups:

```bash
addgroup group0
addgroup group1
```

- Create a user per group:

```bash
adduser user0
adduser user0 group0
adduser user1
adduser user1 group1
```

- Create a user belonging to two groups:

```bash
adduser user2
adduser user2 group0
adduser user2 group1
```

- Delete a user and remove its home directory

```bash
userdel -r username
```

- Update the APT cache and install nginx:

```bash
apt-get update && apt-get install nginx
```

The rest was shown yesterday.