Giter Club home page Giter Club logo

Comments (4)

usiegl00 avatar usiegl00 commented on May 22, 2024 1

Also:

  • Linux /etc/rc.local
  • MacOS /etc/rc.common

from sliver.

usiegl00 avatar usiegl00 commented on May 22, 2024

Persistence is inherently not op-sec safe due to the requirements of storing information on disk.
However I think we should decide on the best methods of persisting on the 3 major OS's. (Linux, MacOS, and Windows)

Possible Options:

  • Linux /tmp/...
    Cron is the most common way to persist on Linux.
    printf "*/5 * * * * /tmp/..." | crontab
  • MacOS
    • User: launchctl
    • Root: emond or sudo /bin/bash -c 'echo "touch /tmp/pwned" > /etc/periodic/daily/000.pwned && chmod +x /etc/periodic/daily/000.pwned'
  • Windows
    • User: Registry Keys or Scheduled Tasks
      [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run]
      [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnce]
      [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunServices]
      [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce]
      [HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Winlogon]
      
      schtasks /create /rp "" /tn "" /tr C:\Windows\System32\mshta.exe js-DotNet-Go /sc onlogon
    • Root: Registry Keys or at.exe
      [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run]
      [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce]
      [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServices]
      [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce]
      [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Winlogon]
      
      C:\Windows\System32\at.exe at 08:00 /every:m,t,w,th,f,s,su C:\Windows\System32\mshta.exe js-DotNet-Go

from sliver.

zero77 avatar zero77 commented on May 22, 2024

These may not all be deemed op safe but, just to give some ideas for other possible Linux options:

/etc/bash.bashrc
/etc/profile
/etc/profile.d/*
~/.profile
~/.bash_login

Also:

from sliver.

vctrferreira avatar vctrferreira commented on May 22, 2024

How is going the development of this feature? Could I help you with any thing?

from sliver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.