-
Notifications
You must be signed in to change notification settings - Fork 1.7k
feat(ui): Add option to define custom css and js #11586
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
DryRun Security SummaryA Django DefectDojo PR introduces global configuration for custom CSS and JavaScript files, presenting potential security risks including XSS vulnerabilities, malicious file inclusion, configuration exposure, and CSP implications. Expand for full summaryThe PR adds global configuration for custom CSS and JavaScript files across the Django DefectDojo application, enabling dynamic UI customization with potential security implications. Security findings include:
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 |
From my point of view, it could be beneficial not just for our company but also for all the others who have defined company design. |
It could be useful. I wonder if we should add a comment about the risks of including/injecting javascript? |
Thank you for the review. Where should I place it? To release notes? Or to the |
I vote for this. |
1172bac
to
3803b3c
Compare
Hi @kiblik, First off, thank you so much for opening this PR — and for everything you’ve been contributing. Your work has made a huge difference, and we’re really lucky to have you involved. We gave this change some serious thought. It’s a really interesting idea, and we can absolutely see why having more flexibility would be helpful. That said, we’re a little hesitant to allow injecting custom JS and CSS directly, mainly because of a few concerns around brand consistency, potential security risks, and the challenges it could create for supporting users. We want to make sure the experience stays stable and predictable for everyone using the project. That said — if there’s a specific problem you’re trying to solve with this, we’d love to work with you to find another way! Maybe there’s a safer or more scoped approach we can take. Thanks again for everything you’re doing — we truly appreciate it. Looking forward to hearing your thoughts! |
Custom styles (in CSS) are beneficial if you are running DD in the company and you would like to add some corporate colors.