Skip to content

Commit e91e7b6

Browse files
committed
Experimentation hax
CI tests go burrrrr
1 parent 6274d04 commit e91e7b6

File tree

3 files changed

+71
-13
lines changed

3 files changed

+71
-13
lines changed

.github/workflows/shared_meterpreter_acceptance.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ jobs:
187187
with:
188188
repository: zeroSteiner/metasploit-framework
189189
path: metasploit-framework
190-
ref: ${{ inputs.metasploit_framework_commit }}
190+
ref: fix/met/java-win-symlink-tests
191191

192192
- name: Setup Ruby
193193
env:
@@ -246,9 +246,9 @@ jobs:
246246
if: ${{ inputs.build_metasploit_payloads && matrix.meterpreter.name != 'mettle' }}
247247
uses: actions/checkout@v4
248248
with:
249-
repository: rapid7/metasploit-payloads
249+
repository: zeroSteiner/metasploit-payloads
250250
path: metasploit-payloads
251-
ref: ${{ inputs.metasploit_payloads_commit }}
251+
ref: fix/met/java/symlinks
252252

253253
- name: Get metasploit-payloads version
254254
if: ${{ inputs.build_metasploit_payloads && matrix.meterpreter.name != 'mettle' }}

spec/support/acceptance/session/java.rb

Lines changed: 64 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,13 @@ module Acceptance::Session
3535
reason: "Windows only test"
3636
}
3737
],
38-
:windows
38+
[
39+
:windows,
40+
{
41+
skip: true,
42+
reason: "Skip while experimenting"
43+
}
44+
]
3945
],
4046
skipped: false,
4147
lines: {
@@ -75,7 +81,13 @@ module Acceptance::Session
7581
},
7682
{
7783
name: "post/test/cmd_exec",
78-
platforms: [:linux, :osx, :windows],
84+
platforms: [:linux, :osx, [
85+
:windows,
86+
{
87+
skip: true,
88+
reason: "Skip while experimenting"
89+
}
90+
]],
7991
skipped: false,
8092
lines: {
8193
linux: {
@@ -91,7 +103,13 @@ module Acceptance::Session
91103
},
92104
{
93105
name: "post/test/extapi",
94-
platforms: [:linux, :osx, :windows],
106+
platforms: [:linux, :osx, [
107+
:windows,
108+
{
109+
skip: true,
110+
reason: "Skip while experimenting"
111+
}
112+
]],
95113
skipped: false,
96114
lines: {
97115
linux: {
@@ -123,7 +141,13 @@ module Acceptance::Session
123141
},
124142
{
125143
name: "post/test/get_env",
126-
platforms: [:linux, :osx, :windows],
144+
platforms: [:linux, :osx, [
145+
:windows,
146+
{
147+
skip: true,
148+
reason: "Skip while experimenting"
149+
}
150+
]],
127151
skipped: false,
128152
lines: {
129153
linux: {
@@ -139,7 +163,13 @@ module Acceptance::Session
139163
},
140164
{
141165
name: "post/test/meterpreter",
142-
platforms: [:linux, :osx, :windows],
166+
platforms: [:linux, :osx, [
167+
:windows,
168+
{
169+
skip: true,
170+
reason: "Skip while experimenting"
171+
}
172+
]],
143173
skipped: false,
144174
lines: {
145175
linux: {
@@ -155,7 +185,13 @@ module Acceptance::Session
155185
},
156186
{
157187
name: "post/test/railgun",
158-
platforms: [:linux, :osx, :windows],
188+
platforms: [:linux, :osx, [
189+
:windows,
190+
{
191+
skip: true,
192+
reason: "Skip while experimenting"
193+
}
194+
]],
159195
skipped: false,
160196
lines: {
161197
linux: {
@@ -171,7 +207,13 @@ module Acceptance::Session
171207
},
172208
{
173209
name: "post/test/railgun_reverse_lookups",
174-
platforms: [:linux, :osx, :windows],
210+
platforms: [:linux, :osx, [
211+
:windows,
212+
{
213+
skip: true,
214+
reason: "Skip while experimenting"
215+
}
216+
]],
175217
skipped: false,
176218
lines: {
177219
linux: {
@@ -202,7 +244,13 @@ module Acceptance::Session
202244
reason: "Windows only test"
203245
}
204246
],
205-
:windows
247+
[
248+
:windows,
249+
{
250+
skip: true,
251+
reason: "Skip while experimenting"
252+
}
253+
]
206254
],
207255
skipped: false,
208256
lines: {
@@ -222,7 +270,13 @@ module Acceptance::Session
222270
},
223271
{
224272
name: "post/test/search",
225-
platforms: [:linux, :osx, :windows],
273+
platforms: [:linux, :osx, [
274+
:windows,
275+
{
276+
skip: true,
277+
reason: "Skip while experimenting"
278+
}
279+
]],
226280
skipped: false,
227281
lines: {
228282
linux: {
@@ -245,7 +299,7 @@ module Acceptance::Session
245299
:windows,
246300
{
247301
skip: true,
248-
reason: "Unix only test"
302+
reason: "Skip while experimenting"
249303
}
250304
]
251305
],

test/modules/post/test/file.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,10 @@ def test_dir
8080
unless (session.platform == 'windows') || (session.platform != 'windows' && command_exists?('ln'))
8181
print_warning('skipping link related checks because the target is incompatible')
8282
else
83+
print_status('*' * 50)
84+
print_status("CWD (cmd): #{cmd_exec("cmd.exe /c echo %cd%")}")
85+
print_status("CWD (met): #{session.fs.dir.getwd}")
86+
print_status('*' * 50)
8387
it 'should delete a symbolic link target' do
8488
# TODO: Fix this functionality
8589
if session.platform.eql?('windows') && session.type.eql?('shell')

0 commit comments

Comments
 (0)