Skip to content

Commit

Permalink
Compile binary with CETCOMPAT (#7)
Browse files Browse the repository at this point in the history
* Compile binary with CETCOMPAT

* bump visual studio version
  • Loading branch information
yardenshafir authored Nov 21, 2022
1 parent 7cdbb4e commit 8c7fe4f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ jobs:
run: |
mkdir build32
cd build32
cmake -G "Visual Studio 16 2019" -A Win32 ..
cmake -G "Visual Studio 17 2022" -A Win32 ..
cmake --build . --config Release
- name: build64
run: |
mkdir build64
cd build64
cmake -G "Visual Studio 16 2019" -A x64 ..
cmake -G "Visual Studio 17 2022" -A x64 ..
cmake --build . --config Release
- name: upload artifacts for winchecksec-scan
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ jobs:
run: |
mkdir build32
cd build32
cmake -G "Visual Studio 16 2019" -A Win32 ..
cmake -G "Visual Studio 17 2022" -A Win32 ..
cmake --build . --config Release
- name: build64
run: |
mkdir build64
cd build64
cmake -G "Visual Studio 16 2019" -A x64 ..
cmake -G "Visual Studio 17 2022" -A x64 ..
cmake --build . --config Release
- name: archive
Expand Down
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ target_link_options(pegoat-no-nxcompat PRIVATE "/NXCOMPAT:NO")
add_executable(pegoat-no-cetcompat goat.cpp)
target_link_options(pegoat-no-cetcompat PRIVATE "/CETCOMPAT:NO")

# An executable with Intel CET (hardware CFI) compatiblity.
add_executable(pegoat-cetcompat goat.cpp)
target_link_options(pegoat-cetcompat PRIVATE "/CETCOMPAT")

# An executable without control flow guards.
add_executable(pegoat-no-cfg goat.cpp)
target_compile_options(pegoat-no-cfg PRIVATE "/GUARD:NO")
Expand Down

0 comments on commit 8c7fe4f

Please sign in to comment.