All Projects → 0xmachos → Mosl

0xmachos / Mosl

Licence: mit
Bash script to audit and fix macOS Catalina (10.15.x) security settings

Programming Languages

shell
77523 projects
bash
514 projects

Projects that are alternatives of or similar to Mosl

Knary
A simple HTTP(S) and DNS Canary bot with Slack/Discord/MS Teams & Pushover support
Stars: ✭ 187 (-13.02%)
Mutual labels:  security-tools
Awesome Bbht
A bash script that will automatically install a list of bug hunting tools that I find interesting for recon, exploitation, etc. (minus burp) For Ubuntu/Debain.
Stars: ✭ 190 (-11.63%)
Mutual labels:  security-tools
Bundler Audit
Patch-level verification for Bundler
Stars: ✭ 2,393 (+1013.02%)
Mutual labels:  security-tools
Apk Medit
memory search and patch tool on debuggable apk without root & ndk
Stars: ✭ 189 (-12.09%)
Mutual labels:  security-tools
Aws Auto Remediate
Open source application to instantly remediate common security issues through the use of AWS Config
Stars: ✭ 191 (-11.16%)
Mutual labels:  security-tools
Containerssh
ContainerSSH: Launch containers on demand
Stars: ✭ 195 (-9.3%)
Mutual labels:  security-tools
Awesome Shodan Queries
🔍 A collection of interesting, funny, and depressing search queries to plug into shodan.io 👩‍💻
Stars: ✭ 2,758 (+1182.79%)
Mutual labels:  security-tools
Ladon
大型内网渗透扫描器&Cobalt Strike,Ladon8.9内置120个模块,包含信息收集/存活主机/端口扫描/服务识别/密码爆破/漏洞检测/漏洞利用。漏洞检测含MS17010/SMBGhost/Weblogic/ActiveMQ/Tomcat/Struts2,密码口令爆破(Mysql/Oracle/MSSQL)/FTP/SSH(Linux)/VNC/Windows(IPC/WMI/SMB/Netbios/LDAP/SmbHash/WmiHash/Winrm),远程执行命令(smbexec/wmiexe/psexec/atexec/sshexec/webshell),降权提权Runas、GetSystem,Poc/Exploit,支持Cobalt Strike 3.X-4.0
Stars: ✭ 2,911 (+1253.95%)
Mutual labels:  security-tools
Pypowershellxray
Python script to decode common encoded PowerShell scripts
Stars: ✭ 192 (-10.7%)
Mutual labels:  security-tools
Pwnback
Burp Extender plugin that generates a sitemap of a website using Wayback Machine
Stars: ✭ 203 (-5.58%)
Mutual labels:  security-tools
Revshellgen
Reverse shell generator written in Python 3.
Stars: ✭ 190 (-11.63%)
Mutual labels:  security-tools
Ansible Role Hardening
Ansible role to apply a security baseline. Systemd edition.
Stars: ✭ 188 (-12.56%)
Mutual labels:  security-tools
Fdsploit
File Inclusion & Directory Traversal fuzzing, enumeration & exploitation tool.
Stars: ✭ 199 (-7.44%)
Mutual labels:  security-tools
Security Scripts
A collection of security related Python and Bash shell scripts. Analyze hosts on generic security vulnerabilities. Wrapper around popular tools like nmap (portscanner), nikto (webscanner) and testssl.sh (SSL/TLS scanner)
Stars: ✭ 188 (-12.56%)
Mutual labels:  security-tools
Limitrr
Light NodeJS rate limiting and response delaying using Redis - including Express middleware.
Stars: ✭ 203 (-5.58%)
Mutual labels:  security-tools
Attack monitor
Endpoint detection & Malware analysis software
Stars: ✭ 186 (-13.49%)
Mutual labels:  security-tools
Replica
Ghidra Analysis Enhancer 🐉
Stars: ✭ 194 (-9.77%)
Mutual labels:  security-tools
Blackhat Arsenal Tools
Official Black Hat Arsenal Security Tools Repository
Stars: ✭ 2,639 (+1127.44%)
Mutual labels:  security-tools
Vulny Code Static Analysis
Python script to detect vulnerabilities inside PHP source code using static analysis, based on regex
Stars: ✭ 207 (-3.72%)
Mutual labels:  security-tools
Zbn
安全编排与自动化响应平台
Stars: ✭ 201 (-6.51%)
Mutual labels:  security-tools

macOS Lockdown (mOSL)

Shellcheck GitHub Release

Bash script to audit and fix macOS Catalina (10.15.x) security settings

Inspired by and based on Lockdown by Patrick Wardle and osxlockdown by Scott Piper.

Warnings

mOSL is being rewritten in Swift and the Bash version will be deprecated.. See: "The Future of mOSL".

  • Always run the latest release not the code in master!
  • This script will only ever support the latest macOS release
  • This script requires your password to invoke some commands with sudo

brew

tap: 0xmachos/homebrew-mosl

To install mOSL via brew execute:

brew tap 0xmachos/homebrew-mosl
brew install mosl

mOSL will then be available as:

Lockdown

Threat Model(ish)

The main goal is to enforce already secure defaults and apply more strict non-default options.

It aims to reduce attack surface but it is pragmatic in this pursuit. The author utilises Bluetooth for services such as Handoff so it is left enabled.

There is no specific focus on enhancing privacy.

Finally, mOSL will not protect you from the FSB, MSS, DGSE, or FSM.

Full Disk Access Permission

In macOS Mojave and later certain application data is protected by the OS. For example, if Example.app wishes to access Contacts.app data Example.app must be given explicit permission via System Preferences > Security & Privacy > Privacy. However some application data cannot be accessed via a specific permission. Access to this data requires the Full Disk Access permission.

mOSL requires that Terminal.app be given the Full Disk Access permission. It needs this permission to audit/fix the following settings:

  • disable mail remote content
  • disable_auto_open_safe_downloads

These are currently the only settings which require Full Disk Access.

It is not possible to programatically get or prompt for this permission, it must be manually given by the user.

To give Terminal.app Full Disk Access:

System Preferences > Security & Privacy > Privacy > Full Disk Access > Add Terminal.app

Once you are done with mOSL you can revoke Full Disk Access for Terminal.app. There's a small checkbox next to Terminal which you can uncheck to revoke the premssion without entirely removing Terminal.app from the list.

More info on macOS's new permission model:

Verification

The executable Lockdown file can be verified with Minisign:

minisign -Vm Lockdown -P RWTiYbJbLl7q6uQ70l1XCvGExizUgEBNDPH0m/1yMimcsfgh542+RDPU

Install via brew: brew install minisign

Usage

$ ./Lockdown 

  Audit or Fix macOS security settings🔒🍎

  Usage: ./Lockdown [list | audit {setting_index} | fix {setting_index} | debug]

    list         - List settings that can be audited/ fixed
    audit        - Audit the status of all or chosen setting(s) (Does NOT change settings)
    fix          - Attempt to fix all or chosen setting(s) (Does change settings)

    fix-force    - Same as 'fix' however bypasses user confirmation prompt
                   (Can be used to invoke Lockdown from other scripts)

    debug        - Print debug info for troubleshooting

Settings

See Commands.md for a easy to read list of commands used to audit/ fix the below settings.

Settings that can be audited/ fixed:

  [0] enable automatic system updates
  [1] enable automatic app store updates
  [2] enable gatekeeper
  [3] enable firewall
  [4] enable admin password preferences
  [5] enable terminal secure entry
  [6] enable sip
  [7] enable filevault
  [8] disable firewall builin software
  [9] disable firewall downloaded signed
  [10] disable ipv6
  [11] disable mail remote content
  [12] disable remote apple events
  [13] disable remote login
  [14] disable auto open safe downloads
  [15] set airdrop contacts only
  [16] set appstore update check daily
  [17] set firmware password
  [18] check kext loading consent
  [19] check efi integrity
  [20] check if standard user
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].