diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index bb94775bb..261cb693c 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -30,7 +30,7 @@ jobs: run: sudo apt-get update - name: Install dependencies - run: sudo apt-get install -yqq make autoconf build-essential ca-certificates pkg-config libreadline-dev gcc-arm-none-eabi libnewlib-dev qt6-base-dev qmake6-bin libbz2-dev liblz4-dev libbluetooth-dev libpython3-dev python3 python3-dev libpython3-all-dev liblua5.4-dev liblua5.4-0 lua5.4 sed libssl-dev libgd-dev + run: sudo apt-get install -yqq make autoconf build-essential ca-certificates pkg-config libreadline-dev gcc-arm-none-eabi libnewlib-dev qt6-base-dev libbz2-dev liblz4-dev libbluetooth-dev libpython3-dev python3 python3-dev libpython3-all-dev liblua5.4-dev liblua5.4-0 lua5.4 sed libssl-dev libgd-dev - name: Install Python dependencies run: pip install -r tools/requirements.txt @@ -60,7 +60,7 @@ jobs: run: sudo apt-get update - name: Install dependencies - run: sudo apt-get install -yqq make autoconf build-essential ca-certificates pkg-config libreadline-dev gcc-arm-none-eabi libnewlib-dev qt6-base-dev qmake6-bin libbz2-dev liblz4-dev libbluetooth-dev libpython3-dev python3 python3-dev libpython3-all-dev liblua5.4-dev liblua5.4-0 lua5.4 sed libssl-dev libgd-dev + run: sudo apt-get install -yqq make autoconf build-essential ca-certificates pkg-config libreadline-dev gcc-arm-none-eabi libnewlib-dev qt6-base-dev libbz2-dev liblz4-dev libbluetooth-dev libpython3-dev python3 python3-dev libpython3-all-dev liblua5.4-dev liblua5.4-0 lua5.4 sed libssl-dev libgd-dev - name: Install Python dependencies run: pip install -r tools/requirements.txt diff --git a/docker/archlinux/Dockerfile b/docker/archlinux/Dockerfile index caaa2bc89..db30f971f 100644 --- a/docker/archlinux/Dockerfile +++ b/docker/archlinux/Dockerfile @@ -1,6 +1,6 @@ FROM archlinux:base -ENV LANG=C +ENV LANG=C.UTF-8 RUN pacman -Syu --noconfirm RUN pacman-db-upgrade # qt5-base skipped diff --git a/docker/build.sh b/docker/build.sh index 9fd6e4bac..a0ca236c1 100755 --- a/docker/build.sh +++ b/docker/build.sh @@ -5,13 +5,13 @@ if [ ! -e docker_conf.inc ]; then exit 1 fi . docker_conf.inc +BUILDARG="${BUILDARG:-""}" + # Make sure to connect a Proxmark3 when building if you want to be able to access it from within the Docker instance UART_PORT="$(../../pm3 --list|grep /dev|head -n1|cut -d' ' -f2)" if [ -n "$UART_PORT" ]; then UART_GID="$(stat -c '%g' $UART_PORT)" - BUILDARG="--build-arg UART_GID=$UART_GID" -else - BUILDARG="" + BUILDARG="$BUILDARG --build-arg UART_GID=$UART_GID" fi if [ -n "$SKIPQT" ]; then diff --git a/docker/debian-13-trixie-arm64/Dockerfile b/docker/debian-13-trixie-arm64/Dockerfile index e65dd9fab..021596859 100644 --- a/docker/debian-13-trixie-arm64/Dockerfile +++ b/docker/debian-13-trixie-arm64/Dockerfile @@ -1,6 +1,6 @@ FROM arm64v8/debian:trixie-slim -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive # qtbase5-dev skipped RUN apt-get update && \ diff --git a/docker/debian-13-trixie-armhf/Dockerfile b/docker/debian-13-trixie-armhf/Dockerfile index a69bdec5c..81c9b1319 100644 --- a/docker/debian-13-trixie-armhf/Dockerfile +++ b/docker/debian-13-trixie-armhf/Dockerfile @@ -1,6 +1,6 @@ FROM arm32v7/debian:trixie-slim -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive # qtbase5-dev skipped RUN apt-get update && \ diff --git a/docker/debian-13-trixie/Dockerfile b/docker/debian-13-trixie/Dockerfile index 5047c6679..1bb7733d0 100644 --- a/docker/debian-13-trixie/Dockerfile +++ b/docker/debian-13-trixie/Dockerfile @@ -1,6 +1,6 @@ FROM debian:trixie-slim -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && \ apt-get upgrade -y && \ @@ -13,9 +13,9 @@ RUN apt-get install -y opencl-dev && \ ARG SKIPQT=false RUN if [ "${SKIPQT}" = "false" ]; then \ - apt-get install -y qt6-base-dev qmake6-bin && \ - apt-get clean; \ - fi + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ @@ -26,9 +26,9 @@ RUN passwd -d rrg ARG UART_GID # dialout group may already exist on another numeric ID than on host RUN if [ -n "${UART_GID}" ]; then \ - groupadd -g ${UART_GID} mydialout || true; \ - usermod -aG ${UART_GID} rrg; \ - fi + groupadd -g ${UART_GID} mydialout || true; \ + usermod -aG ${UART_GID} rrg; \ + fi RUN printf 'rrg ALL=(ALL) ALL\n' | tee -a /etc/sudoers USER rrg diff --git a/docker/debian-13-trixie/docker_conf.inc b/docker/debian-13-trixie/docker_conf.inc index 5e7d4dc09..d4e88960e 100644 --- a/docker/debian-13-trixie/docker_conf.inc +++ b/docker/debian-13-trixie/docker_conf.inc @@ -1,2 +1,2 @@ DOCKER_IMAGE=pm3-debian-trixie:1.0 -SKIPQT=1 +#SKIPQT=1 diff --git a/docker/debian-14-forky/Dockerfile b/docker/debian-14-forky/Dockerfile index cda4babaa..3f9f3b986 100644 --- a/docker/debian-14-forky/Dockerfile +++ b/docker/debian-14-forky/Dockerfile @@ -1,6 +1,6 @@ FROM debian:forky-slim -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive # qtbase5-dev skipped RUN apt-get update && \ @@ -12,6 +12,12 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ diff --git a/docker/debian-14-forky/docker_conf.inc b/docker/debian-14-forky/docker_conf.inc index 3b90349a0..54eeee843 100644 --- a/docker/debian-14-forky/docker_conf.inc +++ b/docker/debian-14-forky/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-debian-forky:1.0 +#SKIPQT=1 diff --git a/docker/fedora-41/Dockerfile b/docker/fedora-41/Dockerfile index c64b5646f..0612b5d3e 100644 --- a/docker/fedora-41/Dockerfile +++ b/docker/fedora-41/Dockerfile @@ -1,6 +1,6 @@ FROM fedora:41 -ENV LANG=C +ENV LANG=C.UTF-8 # qt5-qtbase-devel skipped RUN dnf install -y passwd sudo git make cmake gcc gcc-c++ arm-none-eabi-gcc-cs arm-none-eabi-newlib readline-devel bzip2-devel lz4-devel bluez-libs-devel python3-devel openssl-devel gd-devel libatomic findutils diff --git a/docker/fedora-42/Dockerfile b/docker/fedora-42/Dockerfile index 75516752c..581cc24e0 100644 --- a/docker/fedora-42/Dockerfile +++ b/docker/fedora-42/Dockerfile @@ -1,6 +1,6 @@ FROM fedora:42 -ENV LANG=C +ENV LANG=C.UTF-8 # qt5-qtbase-devel skipped RUN dnf install -y passwd sudo git make cmake gcc gcc-c++ arm-none-eabi-gcc-cs arm-none-eabi-newlib readline-devel bzip2-devel lz4-devel bluez-libs-devel python3-devel openssl-devel gd-devel libatomic findutils diff --git a/docker/fedora-43/Dockerfile b/docker/fedora-43/Dockerfile index 43995fe51..73223cbfd 100644 --- a/docker/fedora-43/Dockerfile +++ b/docker/fedora-43/Dockerfile @@ -1,6 +1,6 @@ FROM fedora:rawhide -ENV LANG=C +ENV LANG=C.UTF-8 # qt5-qtbase-devel skipped RUN dnf install -y passwd sudo git make cmake gcc gcc-c++ arm-none-eabi-gcc-cs arm-none-eabi-newlib readline-devel bzip2-devel lz4-devel bluez-libs-devel python3-devel openssl-devel gd-devel libatomic findutils diff --git a/docker/homebrew/Dockerfile b/docker/homebrew/Dockerfile index d4893d154..d11abd604 100644 --- a/docker/homebrew/Dockerfile +++ b/docker/homebrew/Dockerfile @@ -1,6 +1,6 @@ FROM homebrew/brew -ENV LANG=C +ENV LANG=C.UTF-8 ARG UART_GID # dialout group may already exist on another numeric ID than on host diff --git a/docker/kali/Dockerfile b/docker/kali/Dockerfile index c81861a1f..4b80bf549 100644 --- a/docker/kali/Dockerfile +++ b/docker/kali/Dockerfile @@ -1,6 +1,6 @@ FROM kalilinux/kali-rolling -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive # qtbase5-dev skipped RUN apt-get update && \ @@ -12,6 +12,12 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ diff --git a/docker/kali/docker_conf.inc b/docker/kali/docker_conf.inc index 62f57876b..57373f155 100644 --- a/docker/kali/docker_conf.inc +++ b/docker/kali/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-kali:1.0 +#SKIPQT=1 diff --git a/docker/opensuse-leap/Dockerfile b/docker/opensuse-leap/Dockerfile index 7a86b5503..bed05c810 100644 --- a/docker/opensuse-leap/Dockerfile +++ b/docker/opensuse-leap/Dockerfile @@ -1,6 +1,6 @@ FROM opensuse/leap -ENV LANG=C +ENV LANG=C.UTF-8 # libqt5-qtbase-devel skipped RUN zypper --non-interactive install --no-recommends shadow sudo git patterns-devel-base-devel_basis cmake gcc-c++ readline-devel libbz2-devel liblz4-devel bluez-devel python3-devel libopenssl-devel gd-devel diff --git a/docker/opensuse-tumbleweed/Dockerfile b/docker/opensuse-tumbleweed/Dockerfile index 5c18adbec..9bdfdc051 100644 --- a/docker/opensuse-tumbleweed/Dockerfile +++ b/docker/opensuse-tumbleweed/Dockerfile @@ -1,6 +1,6 @@ FROM opensuse/tumbleweed -ENV LANG=C +ENV LANG=C.UTF-8 # libqt5-qtbase-devel skipped RUN zypper --non-interactive install --no-recommends shadow sudo git patterns-devel-base-devel_basis cmake gcc-c++ readline-devel libbz2-devel liblz4-devel bluez-devel python3-devel libopenssl-devel cross-arm-none-gcc15 cross-arm-none-newlib-devel gd-devel diff --git a/docker/parrot-core-latest/Dockerfile b/docker/parrot-core-latest/Dockerfile index 29faa61ae..25397f60a 100644 --- a/docker/parrot-core-latest/Dockerfile +++ b/docker/parrot-core-latest/Dockerfile @@ -1,6 +1,6 @@ FROM parrotsec/core:latest -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive # qtbase5-dev skipped RUN apt-get update && \ @@ -12,6 +12,12 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ diff --git a/docker/parrot-core-latest/docker_conf.inc b/docker/parrot-core-latest/docker_conf.inc index 6410849ad..c1fa70a3b 100644 --- a/docker/parrot-core-latest/docker_conf.inc +++ b/docker/parrot-core-latest/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-parrotsec-core-latest:1.0 +#SKIPQT=1 diff --git a/docker/rm.sh b/docker/rm.sh index 72aab077b..de48f45e4 100755 --- a/docker/rm.sh +++ b/docker/rm.sh @@ -10,3 +10,4 @@ if [ -n "$CONTAINER" ]; then docker rm $CONTAINER fi docker image rm "$DOCKER_IMAGE" +docker builder prune --force diff --git a/docker/ubuntu-24.04/Dockerfile b/docker/ubuntu-24.04/Dockerfile index de35f65f3..7ac58bf7d 100644 --- a/docker/ubuntu-24.04/Dockerfile +++ b/docker/ubuntu-24.04/Dockerfile @@ -1,8 +1,8 @@ FROM ubuntu:24.04 -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive -# qtbase5-dev skipped + RUN apt-get update && \ apt-get upgrade -y && \ apt-get dist-upgrade -y && \ @@ -12,20 +12,26 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ # Create rrg user => there is already a ubuntu user = 1000 that we need to move away -RUN usermod -u 999 ubuntu -RUN groupmod -g 999 ubuntu +RUN usermod -u 900 ubuntu +RUN groupmod -g 900 ubuntu RUN useradd -ms /bin/bash rrg RUN passwd -d rrg ARG UART_GID # dialout group may already exist on another numeric ID than on host RUN if [ -n "${UART_GID}" ]; then \ - groupadd -g ${UART_GID} mydialout || true; \ - usermod -aG ${UART_GID} rrg; \ - fi + groupadd -g ${UART_GID} mydialout || true; \ + usermod -aG ${UART_GID} rrg; \ + fi RUN printf 'rrg ALL=(ALL) ALL\n' | tee -a /etc/sudoers USER rrg diff --git a/docker/ubuntu-24.04/docker_conf.inc b/docker/ubuntu-24.04/docker_conf.inc index 38c37aff7..78b2c6e76 100644 --- a/docker/ubuntu-24.04/docker_conf.inc +++ b/docker/ubuntu-24.04/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-ubuntu-24.04:1.0 +#SKIPQT=1 diff --git a/docker/ubuntu-25.04/Dockerfile b/docker/ubuntu-25.04/Dockerfile index e5153fbee..237460a4f 100644 --- a/docker/ubuntu-25.04/Dockerfile +++ b/docker/ubuntu-25.04/Dockerfile @@ -1,8 +1,8 @@ FROM ubuntu:25.04 -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive -# qtbase5-dev skipped + RUN apt-get update && \ apt-get upgrade -y && \ apt-get dist-upgrade -y && \ @@ -12,20 +12,26 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ # Create rrg user => there is already a ubuntu user = 1000 that we need to move away -RUN usermod -u 999 ubuntu -RUN groupmod -g 999 ubuntu +RUN usermod -u 900 ubuntu +RUN groupmod -g 900 ubuntu RUN useradd -ms /bin/bash rrg RUN passwd -d rrg ARG UART_GID # dialout group may already exist on another numeric ID than on host RUN if [ -n "${UART_GID}" ]; then \ - groupadd -g ${UART_GID} mydialout || true; \ - usermod -aG ${UART_GID} rrg; \ - fi + groupadd -g ${UART_GID} mydialout || true; \ + usermod -aG ${UART_GID} rrg; \ + fi RUN printf 'rrg ALL=(ALL) ALL\n' | tee -a /etc/sudoers USER rrg diff --git a/docker/ubuntu-25.04/docker_conf.inc b/docker/ubuntu-25.04/docker_conf.inc index 3b0c2e0e3..d50b44f7a 100644 --- a/docker/ubuntu-25.04/docker_conf.inc +++ b/docker/ubuntu-25.04/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-ubuntu-25.04:1.0 +#SKIPQT=1 diff --git a/docker/ubuntu-25.10/Dockerfile b/docker/ubuntu-25.10/Dockerfile index 10b9903eb..886db9dc4 100644 --- a/docker/ubuntu-25.10/Dockerfile +++ b/docker/ubuntu-25.10/Dockerfile @@ -1,8 +1,8 @@ FROM ubuntu:25.10 -ENV LANG=C +ENV LANG=C.UTF-8 ENV DEBIAN_FRONTEND=noninteractive -# qtbase5-dev skipped + RUN apt-get update && \ apt-get upgrade -y && \ apt-get dist-upgrade -y && \ @@ -12,12 +12,18 @@ RUN apt-get update && \ RUN apt-get install -y opencl-dev && \ apt-get clean +ARG SKIPQT=false +RUN if [ "${SKIPQT}" = "false" ]; then \ + apt-get install -y qt6-base-dev && \ + apt-get clean; \ + fi + # uv COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ # Create rrg user => there is already a ubuntu user = 1000 that we need to move away -RUN usermod -u 999 ubuntu -RUN groupmod -g 999 ubuntu +RUN usermod -u 900 ubuntu +RUN groupmod -g 900 ubuntu RUN useradd -ms /bin/bash rrg RUN passwd -d rrg ARG UART_GID diff --git a/docker/ubuntu-25.10/docker_conf.inc b/docker/ubuntu-25.10/docker_conf.inc index 3c512afaa..0327ee04c 100644 --- a/docker/ubuntu-25.10/docker_conf.inc +++ b/docker/ubuntu-25.10/docker_conf.inc @@ -1 +1,2 @@ DOCKER_IMAGE=pm3-ubuntu-25.10:1.0 +#SKIPQT=1 diff --git a/tools/pm3_online_tests.sh b/tools/pm3_online_tests.sh index 998122f62..f939b57da 100755 --- a/tools/pm3_online_tests.sh +++ b/tools/pm3_online_tests.sh @@ -2,7 +2,7 @@ # Online tests that require actual PM3 device connection # This is used to make sure that the language for the functions is english instead of the system default language. -LANG=C +LANG=C.UTF-8 PM3PATH="$(dirname "$0")/.." cd "$PM3PATH" || exit 1 diff --git a/tools/pm3_tests.sh b/tools/pm3_tests.sh index b22e48ed8..2f27a6389 100755 --- a/tools/pm3_tests.sh +++ b/tools/pm3_tests.sh @@ -5,7 +5,7 @@ # SKIPUV=1 ./pm3_tests.sh # This is used to make sure that the language for the functions is english instead of the system default language. -LANG=C +LANG=C.UTF-8 PM3PATH="$(dirname "$0")/.." cd "$PM3PATH" || exit 1