-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
feat(ui): Add option to define custom css and js #11586
base: dev
Are you sure you want to change the base?
Conversation
DryRun Security SummaryThe pull request adds functionality to load custom CSS and JavaScript files in DefectDojo through new environment variables, while also highlighting potential security risks that require careful input validation and sanitization. Expand for full summarySummary: The code changes in this pull request introduce the ability to load custom CSS and JavaScript files in the DefectDojo application. This functionality is implemented through the addition of two new environment variables, From an application security perspective, these changes introduce potential security risks if the custom CSS or JavaScript code is not properly sanitized or validated. Malicious code, such as cross-site scripting (XSS) vulnerabilities, could be executed in the context of the user's browser, potentially leading to a security breach. Additionally, the ability to load custom files could be used to bypass certain security controls, such as content security policy (CSP) restrictions, if the application does not properly validate and sanitize the input. To mitigate these risks, it is crucial to ensure that the custom CSS and JavaScript files are thoroughly reviewed and tested for security vulnerabilities before being deployed to the production environment. Additionally, the application should implement robust input validation and sanitization mechanisms to prevent the injection of malicious code. It is also recommended to follow best practices for managing and updating these custom files to ensure they remain secure over time. Files Changed:
Code AnalysisWe ran |
DryRun Security SummaryThe pull request adds the ability to include custom JavaScript and CSS files in DefectDojo through new settings, enabling application customization while emphasizing the importance of carefully vetting these files for potential security risks. Expand for full summarySummary: The code changes in this pull request focus on adding the ability to include custom JavaScript and CSS files in the DefectDojo application. This is achieved by introducing two new settings, From an application security perspective, these changes provide a way for developers and administrators to extend the functionality and styling of the DefectDojo application. However, it is crucial to ensure that the custom CSS and JavaScript files are properly vetted and do not introduce any security vulnerabilities, such as cross-site scripting (XSS) or code injection issues. Developers should review the content of these files and ensure that they are properly sanitized and validated before including them in the application. Additionally, it is recommended to implement a secure process for managing and updating these custom files, such as using a version control system and implementing appropriate access controls and review processes. This will help to mitigate the potential risks associated with the introduction of custom code into the application. Files Changed:
Code AnalysisWe ran |
Custom styles (in CSS) are beneficial if you are running DD in the company and you would like to add some corporate colors.