@@ -67,74 +67,20 @@ jobs:
6767 ref : ${{ matrix.rsync_ref }}
6868 fetch-depth : 1
6969
70- - name : Create SHA test script
71- run : |
72- cat > rsync_repo/testsuite/sha-test.test << 'EOF'
73- #!/bin/sh
74- # Use rsync binary from current directory or parent directory
75- if [ -f "./rsync" ]; then
76- RSYNC="./rsync"
77- elif [ -f "../rsync" ]; then
78- RSYNC="../rsync"
79- else
80- echo "ERROR: Could not find rsync binary"
81- exit 1
82- fi
83- # Verify SHA256 and SHA512 are available
84- if $RSYNC --version | grep -A1 "Daemon auth list:" | grep -q "sha512.*sha256"; then
85- echo "PASS: SHA256 and SHA512 available"
86- else
87- echo "FAIL: SHA256/SHA512 not found"
88- exit 1
89- fi
90- # Verify OpenSSL crypto is enabled
91- if $RSYNC --version | grep -q "openssl-crypto"; then
92- echo "PASS: OpenSSL crypto enabled"
93- else
94- echo "FAIL: OpenSSL crypto not enabled"
95- exit 1
96- fi
97- # Test daemon authentication
98- TEST_DIR="/tmp/rsync-sha-test"
99- SECRETS_FILE="$TEST_DIR/secrets"
100- CONFIG_FILE="$TEST_DIR/rsyncd.conf"
101- rm -rf "$TEST_DIR"
102- mkdir -p "$TEST_DIR"
103- echo "testuser:testpass" > "$SECRETS_FILE"
104- chmod 600 "$SECRETS_FILE"
105- cat > "$CONFIG_FILE" << EOC
106- port = 8730
107- [test]
108- path = /tmp
109- auth users = testuser
110- secrets file = $SECRETS_FILE
111- EOC
112- $RSYNC --daemon --config="$CONFIG_FILE" &
113- DAEMON_PID=$!
114- sleep 3
115- if echo "testpass" | $RSYNC --list-only --password-file=- rsync://testuser@localhost:8730/test/ >/dev/null 2>&1; then
116- echo "PASS: SHA authentication works"
117- else
118- echo "FAIL: SHA authentication failed"
119- kill $DAEMON_PID 2>/dev/null
120- rm -rf "$TEST_DIR"
121- exit 1
122- fi
123- kill $DAEMON_PID 2>/dev/null || true
124- rm -rf "$TEST_DIR" || true
125- exit 0
126- EOF
127- chmod +x rsync_repo/testsuite/sha-test.test
128-
12970 - name : Build and install rsync
13071 working-directory : rsync_repo
13172 run : |
13273 # Set up the environment for wolfProvider
13374 source $GITHUB_WORKSPACE/scripts/env-setup
13475 ./configure --disable-xxhash
76+
77+ # Run the patch script from wolfProvider
78+ $GITHUB_WORKSPACE/.github/scripts/add-rsync-sha-test.sh
79+
13580 make -j$(nproc)
13681 #export RSYNC_CHECKSUM_LIST="none"
13782 #This can disable file checksums which currently use rsycs own implementation of MD4 and MD5
83+ #Causes a lot of tests in the make check to fail so im keeping it disabled
13884
13985 - name : Run rsync tests
14086 working-directory : rsync_repo
0 commit comments