Git Product home page Git Product logo

csf_project's Introduction

Linux Persistence Detection

This script is aimed at aiding an investigator at finding possible signs of malicious persistent access on a system. The methods and output are defined below.

Authors

Will McDonnell - [email protected]

Michael Milkovich - [email protected]

Install and Run

pip3 install -r requirements.txt

Requires sudo to access all files for persistence detection

sudo python3 persistence.py

Output

Two files will be created after successful execution of the script

  • report.txt
  • user_bash.zip

Report

Hidden executable - any files on the system that are both hidden (start with '.') and are marked as executable by a user (https://attack.mitre.org/techniques/T1158/)

Setuid files - any files with a setuid bit on. This will allow any user to run the executable as the owner (https://attack.mitre.org/techniques/T1166/)

Setgid directories - any directories with setgid bit on. File is run with permissions of the group (https://attack.mitre.org/techniques/T1166/)

Users

https://attack.mitre.org/techniques/T1098/

Scheduled tasks - list of crontab info. Can find any persistence mechanism with scheduled tasks (https://attack.mitre.org/techniques/T1168/)

Chrome extensions - if applicable, will list ID or name (if possible) of chrome extension (https://attack.mitre.org/techniques/T1176/)

Group membership (https://attack.mitre.org/techniques/T1098/)

Active sessions - validate all current logged in users

User Bash

All users' bashrc and bash_profile files will be added to a zip file to be manually inspected for any malicious modification (https://attack.mitre.org/techniques/T1156/)

Resources

For a comprehensive list of persistence techniques, see https://attack.mitre.org/

csf_project's People

Contributors

wjm5004 avatar

Forkers

forensictools

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.