NucX is a powerful and user-friendly Flask-based web application designed to streamline the creation of Nuclei templates for automated vulnerability scanning. Tailored for cybersecurity professionals, ethical hackers, and penetration testers, NucX-AI combines advanced AI capabilities with a robust backend architecture. At its core, the application leverages the Gemini API to generate dynamic and well-structured YAML templates based on user-defined vulnerability data such as name, description, type, and severity. These templates are aligned with Nuclei’s best practices to minimize false positives and enhance scanning efficiency.
Generates Nuclei-compatible YAML templates using the Gemini API, ensuring accuracy and adherence to best practices.
Modern authentication system powered by Firebase, with support for access keys and waitlist-based sign-ups.
Clean, mobile-friendly design with intuitive navigation and real-time error feedback.
Detailed logging for all major operations and errors, ensuring traceability and easier debugging.
NucX is built with Flask and integrates Firebase for authentication and Firestore for data storage. It uses the Gemini API for AI-powered template generation and supports secure session management with Flask. The application is production-ready, supporting deployment with Gunicorn and secure configuration management using a `.env` file.
@app.route('/generate', methods=['POST']) def generate(): """Generate a Nuclei template based on the provided vulnerability details""" try: # Get form data vulnerability_name = request.form.get('vulnerability_name', '') vulnerability_description = request.form.get('vulnerability_description', '') vulnerability_type = request.form.get('vulnerability_type', 'http') severity = request.form.get('severity', 'medium') # Validate inputs if not vulnerability_name or not vulnerability_description: flash('Please provide both a vulnerability name and description', 'danger') return redirect(url_for('index')) # Generate template using Gemini API template_yaml = generate_nuclei_template( vulnerability_name=vulnerability_name, vulnerability_description=vulnerability_description, vulnerability_type=vulnerability_type, severity=severity ) # Validate the YAML is_valid, validation_message = validate_yaml(template_yaml) if not is_valid: flash(f'Generated YAML is invalid: {validation_message}', 'warning') # Still show the generated YAML, but with a warning # Store in session for potential download session['last_generated_template'] = template_yaml return render_template('result.html', template_yaml=template_yaml, vulnerability_name=vulnerability_name, is_valid=is_valid) except Exception as e: logger.error(f"Error generating template: {str(e)}", exc_info=True) flash(f'An error occurred while generating the template: {str(e)}', 'danger') return redirect(url_for('index'))
NucX has revolutionized the process of creating Nuclei templates by leveraging AI to generate accurate and efficient YAML templates. This has significantly reduced the time and effort required for template creation, enabling security professionals to focus on vulnerability scanning and remediation. The platform’s secure and user-friendly design ensures accessibility while maintaining high standards of data protection.