Skip to content

Conversation

@CristiMacovei
Copy link

Made changes to compile the project on linux targets using gcc version 12.2.

  • a variable named debug was defined in two places in dfu-util/

    • changed dfu-util/dfu.h: removed declaration of debug variable
    • changed dfu-util/sam7dfu.c: added extern declaration of debug
    • kept definition in dfu-util/main.c
  • a variable named endianness was already defined and redefined inside ipsw-patch/main.c and xpwn/src/xpwn.cpp

    • added extern modifier to the declaration

@CristiMacovei CristiMacovei changed the title changes to compile on linux with gcc v12 changes to compile on linux with gcc v12 + Dockerfile Mar 6, 2025
@razvand razvand self-requested a review May 2, 2025 03:40
@razvand razvand self-assigned this May 2, 2025
Copy link
Member

@razvand razvand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please improve the commit messages. Use instructions here.

Also, I would add / update the README file with instructions on using the Dockerfile.

Dockerfile Outdated
Comment on lines 3 to 5
RUN apt update && apt upgrade -y

RUN apt install -y git cmake build-essential libz-dev libssl-dev libbz2-dev libpng-dev libusb-dev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
RUN apt update && apt upgrade -y
RUN apt install -y git cmake build-essential libz-dev libssl-dev libbz2-dev libpng-dev libusb-dev
RUN set -xe; \
apt-get -yqq update; \
apt-get install -y git cmake build-essential libz-dev libssl-dev libbz2-dev libpng-dev libusb-dev \
;

This commit makes docker `COPY` from the local files, instead of pulling the codebase from git.

In addition, good-practice changes have been added to the `Dockerfile`, such as replacing `apt`
with `apt-get` and adding a newline to the end of the file.

Signed-off-by: CristiMacovei <[email protected]>
Signed-off-by: CristiMacovei <[email protected]>
@razvand razvand self-requested a review August 12, 2025 05:04
Copy link
Member

@razvand razvand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update your commit messages to follow the best practices in creating commits and commit descriptions.

That is:

  1. Use your full name for signing-off and for commit authorship: Cristian Macovei <[email protected]>.
  2. Start sentences with capital letters, e.g. use Improve instead of improve.
  3. When you add a new file, do not use the verb Add. Use the verb Introduce.
  4. Use capitalized words for names, e.g. Git instead of git, GCC instead of GCC.
  5. Add a detailed description for commit messages, e.g. the commit add Docker pipeline (the first line should be Introduce Docker pipeline - followed by an extended description). Same for add Dockerfile and changes to compile on linux with gcc v12 (which should be Update code to build on Linux with GCC >= 12.

You can also build your own image locally:

```sh
xpwn $ docker build -t <container_name> .
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
xpwn $ docker build -t <container_name> .
docker build -t <container_name> .

@@ -0,0 +1,27 @@
# Docker usage instructions
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Docker usage instructions
# Docker Usage Instructions


### Setup

Container images are available on [the github container registry](https://github.com/orgs/malus-security/packages/container/package/xpwn) (and soon on the gitlab container registry).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Container images are available on [the github container registry](https://github.com/orgs/malus-security/packages/container/package/xpwn) (and soon on the gitlab container registry).
Container images are available on [the GitHub Container Registry](https://github.com/orgs/malus-security/packages/container/package/xpwn) (and soon on the GitLab Container Registry).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants