You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MASTR is a security-focused embedded system that establishes a secure communication channel between a host system and a hardware token (Raspberry Pi Pico W/Pico 2 W + ATECC608A). It utilizes a three-phase protocol to ensure mutual attestation, secure channel establishment, and runtime integrity verification.
4
4
5
+
Navigate to [Quick Start Guide](#quick-start-guide) to get started.
@@ -23,7 +25,6 @@ MASTR is a security-focused embedded system that establishes a secure communicat
23
25
-[Software Requirements](#software-requirements)
24
26
-[Quick Start Guide](#quick-start-guide)
25
27
-[Building the Firmware](#building-the-firmware)
26
-
-[Build for Raspberry Pi Pico W](#build-for-raspberry-pi-pico-w)
27
28
-[Build for Raspberry Pi Pico 2 W (RP2350)](#build-for-raspberry-pi-pico-2-w-rp2350)
28
29
-[Flashing the Firmware](#flashing-the-firmware)
29
30
-[Build Options](#build-options)
@@ -47,8 +48,6 @@ MASTR is a security-focused embedded system that establishes a secure communicat
47
48
-[Protocol Errors](#protocol-errors)
48
49
-[TPM2 Issues](#tpm2-issues)
49
50
-[Project Structure](#project-structure)
50
-
-[Additional Resources](#additional-resources)
51
-
-[Contributing](#contributing)
52
51
-[License](#license)
53
52
54
53
---
@@ -115,10 +114,10 @@ Before you begin, ensure you have the following installed and configured:
115
114
116
115
#### Hardware Requirements
117
116
118
-
-**Raspberry Pi Pico W** or **Raspberry Pi Pico 2 W** (with WiFi)
119
-
-**ATECC608A** secure element (connected via I2C at address 0x6A)
117
+
-**Raspberry Pi Pico 2 W** (with WiFi)
118
+
-**ATECC608A/B/C** secure element (connected via I2C at address 0x35) i2c address is configurable
120
119
-**USB cable** for programming and serial communication
121
-
-**Host computer** (Linux, macOS, or Windows)
120
+
-**Host computer** (Linux, macOS, or POSIX Compliant OS ONLY)
122
121
123
122
#### Software Requirements
124
123
@@ -173,11 +172,6 @@ git submodule update --init
173
172
export PICO_SDK_PATH=$(pwd)
174
173
```
175
174
176
-
**Windows:**
177
-
- Install ARM GCC from [ARM Downloads](https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads)
178
-
- Install CMake from [cmake.org](https://cmake.org/download/)
179
-
- Clone Pico SDK and set `PICO_SDK_PATH` environment variable
180
-
181
175
---
182
176
183
177
## Quick Start Guide
@@ -187,38 +181,41 @@ Follow these steps to get MASTR up and running from zero to a fully provisioned,
187
181
### Step 1: Clone the Repository
188
182
189
183
```bash
190
-
git clone <repository-url>
184
+
git clone https://github.com/LLJY/MASTR
191
185
cd MASTR-NEW
192
186
```
193
187
194
188
### Step 2: Build the Firmware
195
189
196
190
```bash
197
-
# For Raspberry Pi Pico W
191
+
# For Raspberry Pi Pico 2W
198
192
mkdir build
199
193
cd build
200
-
cmake .. -DPICO_BOARD=pico_w
201
-
make
202
-
cd ..
194
+
# compiling in debug mode recommended for testing
195
+
cmake .. -DPICO_BOARD=pico2_w -DENABLE_DEBUG=ON
196
+
make -j$(nproc)
203
197
```
204
198
205
-
### Step 3: Flash the Firmware
199
+
### Step 3: Flash the Firmware (Picotool recommended)
206
200
207
-
1. Hold down the **BOOTSEL** button on your Pico W
208
-
2. Connect the Pico W to your computer via USB
209
-
3. The Pico W will appear as a mass storage device (RPI-RP2)
210
-
4. Copy the firmware file to the device:
201
+
Run the following command in the `build` folder:
211
202
```bash
212
-
cp build/mastr.uf2 /media/$USER/RPI-RP2/
203
+
picotool load -f pico_project_template.uf2
213
204
```
214
-
(On Windows: drag and drop to the RPI-RP2 drive)
215
-
5.The Pico W will automatically reboot and start running MASTR
205
+
206
+
The Pico W will automatically reboot and start running MASTR
216
207
217
208
### Step 4: Install Host Dependencies
218
209
219
210
```bash
220
211
cd host/
221
212
pip install -r requirements.txt
213
+
214
+
# pytss may fail to install due to wheel building, please get your distrubution specific version.
215
+
# Ubuntu
216
+
sudo apt-get install python3-tpm2-pytss
217
+
218
+
# you will also require build-essentials, tpm2-tools
222
219
```
223
220
224
221
### Step 5: Provision the System
@@ -238,71 +235,49 @@ You should see successful authentication and a secure channel established!
238
235
239
236
## Building the Firmware
240
237
241
-
The firmware runs on Raspberry Pi Pico/Pico W with FreeRTOS and uses CMake for building.
242
-
243
-
### Build for Raspberry Pi Pico W
244
-
245
-
```bash
246
-
# From project root
247
-
mkdir build
248
-
cd build
249
-
250
-
# Configure for Pico W (RP2040 with WiFi)
251
-
cmake .. -DPICO_BOARD=pico_w
252
-
253
-
# Build
254
-
make
255
-
256
-
# The output file will be: build/mastr.uf2
257
-
```
238
+
The firmware currently only runs on the Pico 2W, the standard Pico W is supported, but not tested.
0 commit comments