-
Notifications
You must be signed in to change notification settings - Fork 998
Update installer to organize packages by categories #672
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
Conversation
65d91a5
to
f316eb6
Compare
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.
@sara-rn the installer here is broken because #671 broke the installer. Please rebase after #675 is merged so that the code works.
The fist UI window (install customization) is missing a next button, so I couldn't test the categories page:
Please address this issue so that I can review the new window as well.
Remember adding labels to PRs (in this case enhacement
is appropriate) and to add the issue the PR closes to the PR description (this PR should address #578).
f7c4e94
to
3100f2b
Compare
After the initial form to set up the environmental variables a new window will display all the packages grouped by category. The packages from `config.xml` will be selected by default.
6caf0ca
to
8aa429c
Compare
@Ana06 there is no need to use |
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.
@sara-rn I was not able to review the installer UI as the installer does not run correctly:
Get-Packages-Categories : The term 'Get-Packages-Categories' is not recognized as the name of a cmdlet, function,
script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
correct and try again.
At C:\Users\flare\Desktop\install.ps1:491 char:27
+ $packagesByCategory = Get-Packages-Categories
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (Get-Packages-Categories:String) [], ParentContainsErrorRecordException
+ FullyQualifiedErrorId : CommandNotFoundException
I think is because you have placed the code of Get-Packages-Categories
after the use of the function (it needs to be defined before). Please ensure the code works as it otherwise make it the review difficult.
I also recommend you to add some screenshots when making UI changes.
I executed it without any issues, but when I switched to a different snapshot with Powershell version 5.1 I had the same error |
84595c3
to
8d8d15e
Compare
2ad68c8
to
94db0a1
Compare
94db0a1
to
092be02
Compare
Retrieve packages from the APIurl `https://www.myget.org/F/vm-packages` instead of using `Find-Package` that required the installation of nuget
Going through the PR now - really nice work! I think this will make customization very smooth. I didn't notice any issues and the installation appears to have kicked off without any problems. Just a few thoughts/observations:
Again, just some thoughts and no issues to report - can't wait to see this PR go live! |
Thanks for taking a look @jstrosch, great feedback!
I agree,
This is a good idea, but I think it is not possible (or at least difficult) to implement. Our packages normally don't contain the tool, just a download link to use to install it. What is useful is to know the installed tool size, but there is no way to know without installing the tool. One thing that we could easily do is to add this information in the description for packages like visualstudio.vm and pdbresym.vm, that we know increase the size of the VM significantly (reason why they are not in the default configuration). For example:
This is more or less already possible providing a configuration file. We could store more than one configuration file in this repository and display them in the UI (for example in the first UI). The issue with this is that we have to maintain all the configuration files adding new tools to several of them (and we already forget to add tools now and we have only one config 😓). At the moment we have just one configuration file that contains what FLARE think is required to do malware analysis efficiently without an important size increase (mostly what FLARE uses internally). This is related to #668. |
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.
Mostly nitpicks here, PR overall looks great 😃
Please check that the "Cancel" buttons are working as intended. I ran the script from an elevated PowerShell console and when I cancelled the GUI disappeared, but I was stuck at the PowerShell console. I didn't see any exit messages and ctrl+c
didn't work to exit it. However, when I debugged it in PowerShell ISE it seemed to work fine and also print the exit message. 🤷
e9e633a
to
58d7cc9
Compare
@MalwareMechanic I cannot reproduce the scenario you mention, both cancel buttons are expected to exit and print the message. I am not sure how to address this. |
27624cd
to
686d498
Compare
Thanks @Ana06 @MalwareMechanic and @jstrosch for the feedback, much appreciated! I have addressed the proposed changes. I believe the overall look and feel can be improved such as the usage of icons or the background.png that we don't use. @jstrosch I like your idea regarding the usage of profiles, this is what commando-vm has, but I agree with Ana we would need to maintain it, no issues if everyone finds it useful. An idea for another PR would be to save the selected packages into a custom config for example so next time you can provide it as a command-line. Just some random thoughts. Thanks again all!! |
I reduced the height of the first Window, not sure if I should also move the Install and Cancel buttons to the right in the second Window or its already fine. |
$resetButton.Add_Click({Set-InitialPackages})#it doesn't work | ||
|
||
$allPackagesButton = New-Object system.Windows.Forms.Button | ||
$allPackagesButton.text = "Select All" |
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 think the exit message not being rendered is caused by #541 (confusing but unrelated to the changes here). I can't reproduce the stuck after exist on the PowerShell console, but the way to exit hasn't been changed in this PR. So if there is an issue, I think it is not caused by these changes. @MalwareMechanic can you double-check that this happens consistently and open an issue if so? Then we can investigate the issue after this has been merged. |
I think it is better to keep the windows as consistent and similar as possible. |
Make the font bigger of packages Add extra space at the end of the checkboxes Add documentation in the function Get-Packages-Categories Apply suggestions from code review
686d498
to
0d8d211
Compare
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.
@sara-rn I have tested again and everything looks as expected. This is a great improvement, thanks for all the work! 🚀
[nitpick] I think it would be nice to add a Back button in the second window (to go back to the first one).
Changes addressed! Thanks for the review
Update installer so that after the initial form to set up the environmental variables a new window displays all the packages grouped by category.
config.xml
need to be selected by default.Closes #578
Closes #546
Closes #432