-
Notifications
You must be signed in to change notification settings - Fork 0
82 lines (66 loc) · 2.44 KB
/
global-checks.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: global-checks
on:
push:
branches: [ main, WIP ]
pull_request:
branches: [ main, WIP ]
jobs:
build-check-global:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Build Executable
run: |
python -m nuitka --follow-imports --assume-yes-for-downloads --remove-output --onefile --output-filename=py-shield --windows-icon-from-ico=icon.ico --company-name="ByteCorum" --product-name="Py-Shield" --file-version=2.0.1.5 --product-version=2.0.1.5 --file-description="Program/Library for Python created to protect your code from decompilation and detection by antiviruses" --copyright="https://github.com/ByteCorum/Py-Shield/blob/main/LICENSE" py-shield.py
- name: Archive Executable
uses: actions/upload-artifact@v4
with:
name: py-shield-executable
path: py-shield.exe
obfuscation-test-global:
needs: build-check-global
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Download Executable
uses: actions/download-artifact@v4
with:
name: py-shield-executable
path: ""
- name: Prepare For Tests
run: |
move "py-shield.exe" "examples/multifile-global"
Remove-Item -Path "examples\multifile-global\obfuscated" -Recurse -Force
- name: Obfuscate
working-directory: examples\multifile-global
run: |
.\py-shield.exe --mode "hashstr;crypt;looping;aes" --loops 3 --output obfuscated --follow imports --files lib.py main.py
- name: Testing
working-directory: examples\multifile-global\obfuscated
run: |
$OUTPUT = $(python main.py)
Write-Host "Output: "
Write-Host $OUTPUT
Write-Host "Result: "
if ($OUTPUT -eq "hello world") {
Write-Host "Success: main.py output contains 'hello world'"
} else {
Write-Host "Failure: main.py output does not contain 'hello world'"
exit 1
}