guervild / uru

GNU General Public License v3.0
79 stars 9 forks source link

generated code missing readBanana/writeBanana function declaration #4

Closed audibleblink closed 2 years ago

audibleblink commented 2 years ago

Generation command:

❯❯ uru generate -c config.yml -p thing.exe --exe --parameters "1.2.3.4 9090"
Stack Trace ``` 2:32PM FTL Error during build: error exit status 2: # huufoimw ./20220514_uwyS_main.go:17:5: imported and not used: "golang.org/x/sys/windows" ./20220514_uwyS_main.go:38:19: undefined: readBanana ./20220514_uwyS_main.go:45:8: undefined: writeBanana ./20220514_uwyS_main.go:52:18: undefined: readBanana ```
Minimal Config to repro ``` payload: artifacts: - name: windows/bananaphone/local/go-shellcode-syscall type: injector type: dll arch: x64 debug: false ```
guervild commented 2 years ago

Hello @audibleblink

Yes, I forgot some stuff 😬

I fix it in c2c32064ad6be037353ed50f0ebbc41d026d36d1

It should work, do not hesitate if i can help ! 😄

audibleblink commented 2 years ago

oh nice. just missed your other comment.

with the same command and config I still get:

2:55PM FTL Error during build: error exit status 2: # ovrdcnds
./20220514_jqLZ_main.go:17:5: imported and not used: "golang.org/x/sys/windows"
audibleblink commented 2 years ago

err. sorry, not same config. This config

payload:
  artifacts:
    - name: windows/bananaphone/local/go-shellcode-syscall
      type: injector
    - name: patchetw
      type: evasion
      args:
        - name: UseBanana
          value: true
  type: dll
  arch: x64
  debug: false
2:55PM FTL Error during build: error exit status 2: # ovrdcnds
./20220514_jqLZ_main.go:17:5: imported and not used: "golang.org/x/sys/windows"

edit:

If i delete:

      args:
        - name: UseBanana
          value: true

it runs perfectly.

guervild commented 2 years ago

Oh i see why, when using banana it do not use "golang.org/x/sys/windows" Good catch, will push a fix !

guervild commented 2 years ago

Let me know if it is better with this patch fa5ed56a2972f27e5cb2b7488e7d4dbb13b29cdd

Edit:

Sorry if the commit is not clear, it seems there was a crlf / lf bug ^^

audibleblink commented 2 years ago

works great! thanks!