-
Notifications
You must be signed in to change notification settings - Fork 14.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding Windows Automation #16698
Adding Windows Automation #16698
Conversation
Similar to the wrapping of the ERB script for Linux. Not sure if this is the best location for the script, but the alternative was an unattributed Gist!
Param( | ||
$DownloadURL = "https://windows.metasploit.com/metasploitframework-latest.msi", | ||
$DownloadLocation = "$env:APPDATA/Metasploit", | ||
$InstallLocation = "C:\Tools", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's double check that the installer will work with this target location. See rapid7/metasploit-omnibus#144
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked and the target installation path is correct (C:\Tools
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @istairbn for your contribution! I tested and the PowerShell script works as expected. Before it lands, I just left a couple of minor comments for you to review, when you get a chance.
@@ -30,6 +30,33 @@ Download the [latest Windows installer](https://windows.metasploit.com/metasploi | |||
|
|||
If you downloaded Metasploit from us, there is no cause for alarm. We pride ourselves on offering the ability for our customers and followers to have the same toolset that the hackers have so that they can test systems more accurately. Because these (and the other exploits and tools in Metasploit) are identical or very similar to existing malicious toolsets, they can be used for nefarious purposes, and they are often flagged and automatically removed by antivirus programs, just like the malware they mimic. | |||
|
|||
## Windows Installation (Silent) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe this could be included in the Installing Metasploit on Windows
section?
## Windows Installation (Silent) | |
### Silent Installation |
Param( | ||
$DownloadURL = "https://windows.metasploit.com/metasploitframework-latest.msi", | ||
$DownloadLocation = "$env:APPDATA/Metasploit", | ||
$InstallLocation = "C:\Tools", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked and the target installation path is correct (C:\Tools
).
@@ -30,6 +30,33 @@ Download the [latest Windows installer](https://windows.metasploit.com/metasploi | |||
|
|||
If you downloaded Metasploit from us, there is no cause for alarm. We pride ourselves on offering the ability for our customers and followers to have the same toolset that the hackers have so that they can test systems more accurately. Because these (and the other exploits and tools in Metasploit) are identical or very similar to existing malicious toolsets, they can be used for nefarious purposes, and they are often flagged and automatically removed by antivirus programs, just like the malware they mimic. | |||
|
|||
## Windows Installation (Silent) | |||
|
|||
The PowerShell below will download and install the framework, and is suitable for automated Windows deployments. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be interesting to add a line saying that the installer will be downloaded to $DownloadLocation
and won't be deleted after the script has run.
Hi @istairbn, this PR is almost good to go and just need some small updates, as I mentioned in my previous comments. Since these changes are minor, I can make them myself and land it. That said, I'll wait a couple of days before doing so, in case you have anything else to add. |
This adds a simple automation script for Windows Installation - suitable for Ansible deployments etc.