Skip to content
Snippets Groups Projects
Commit 6fe0eab8 authored by zkb25's avatar zkb25
Browse files

Im bringing files over from the github

parent 35b3bf81
No related branches found
No related tags found
No related merge requests found
.DS_Store 0 → 100644
File added
# .gitignore
node_modules/
.env
# Senior Design
**Proposal for a Website for Phishing and Suspicious file Detection**
By Phoi Luong, Zoey Bennett, and Christina Krebs
Our project is a comprehensive web-based malware detection platform designed to help users identify and address potential security threats. Users can submit suspicious links or upload files for analysis, and the platform will conduct URL checks for malicious patterns, SSL certificate validity, and other indicators of potential danger. Uploaded files are analyzed using integrated APIs such as VirusTotal, providing detailed insights into threats like malware, phishing, or other vulnerabilities.
The platform generates user-friendly reports that include risk levels, the origin of threats, and actionable recommendations, enabling users to make informed decisions about their submissions. To further support users, the platform features a dedicated learning section for those who may be unsure about handling suspicious files or links. This section covers common phishing attacks, tips for recognizing malicious content, and instructions on how to report suspicious emails or files to appropriate authorities
**Technologies Used**
1. GitHub for project management/development
2. Front-end
1. HTML, CSS, JavaScript
2. For user interface, we want to develop a simple landing page that prompts users to submit a file or URL
3. After some time, once the submitted information
3. Back-end
1. Nodejs
2. Will handle backend processing, such as analyzing URL structures and communicating with external APIs like VirusTotal or Google Safe Browsing.
4. Database
1. PostgreSQL (to store flagged URLs and files)
5. APIs
1. API Integration:
1. **URL Analysis:** Validate URLs and send them to Google Safe Browsing or VirusTotal.
2. **File Scanning:** Upload files to VirusTotal for analysis.
3. **SSL Certification Validation:** VirusTotal
6. Deployment
1. Fly.io for web hosting
{
"folders": [
{
"name": "SeniorDesign",
"path": "."
}
],
"settings": {}
}
\ No newline at end of file
require('dotenv').config();
const { Pool } = require('pg');
const pool = new Pool({
user: process.env.DB_USER,
host: process.env.DB_HOST,
database: process.env.DB_NAME,
password: process.env.DB_PASSWORD,
port: process.env.DB_PORT,
});
pool.connect()
.then(() => console.log('Connected to PostgreSQL'))
.catch(err => console.error('Database connection error:', err));
module.exports = pool;
\ No newline at end of file
This diff is collapsed.
{
"dependencies": {
"axios": "^1.7.9",
"cors": "^2.8.5",
"dotenv": "^16.4.7",
"express": "^4.21.2",
"multer": "^1.4.5-lts.1",
"pg": "^8.13.3"
},
"devDependencies": {
"nodemon": "^3.1.9"
},
"scripts": {
"start": "nodemon server.js"
}
}
<style>
body {
background-color: white;
margin: 0;
padding: 0;
font-family: Arial, sans-serif;
}
nav {
display: flex;
justify-content: flex-end;
background-color: white;
padding: 15px 60px;
font-family: 'Inter', sans-serif;
}
nav a {
margin: 0px 20px;
text-decoration: none;
color: black;
}
.about_section {
background-color: #8FA4CE;
text-align: center;
padding: 30px;
color: white;
}
.about_section h1 {
font-family: 'IBM Plex Mono', monospace;
}
.container {
width: 80%;
margin: 20px auto;
}
.profile {
display: flex;
align-items: center;
background: #EAF1FF;
padding: 20px;
margin: 20px 0;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}
.profile img {
width: 100px;
height: 100px;
border-radius: 50%;
margin-right: 20px;
border: 5px solid #646ab0;
}
.content {
flex: 1;
}
.content h3 {
margin: 0;
}
.icons {
float: right;
}
</style>
\ No newline at end of file
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="CSS/style.css">
<title>About</title>
</head>
<body>
<nav>
<a href="about.html">About</a>
<a href="learn.html">Learn</a>
<a href="https://github.com/Skytex11/SeniorDesign">Github</a>
</nav>
<div class="about_section">
<h1>ABOUT</h1>
<p>Our project is a comprehensive web-based malware detection platform designed to help users identify and address potential security threats. Users can submit suspicious links or upload files for analysis, and the platform will conduct URL checks for malicious patterns, SSL certificate validity, and other indicators of potential danger. Uploaded files are analyzed using integrated APIs such as VirusTotal, providing detailed insights into threats like malware, phishing, or other vulnerabilities.</p>
<p>The platform generates user-friendly reports that include risk levels, the origin of threats, and actionable recommendations, enabling users to make informed decisions about their submissions. To further support users, the platform features a dedicated learning section for those who may be unsure about handling suspicious files or links. This section covers common phishing attacks, tips for recognizing malicious content, and instructions on how to report suspicious emails or files to appropriate authorities.</p>
</div>
<div class="container">
<div class="profile">
<img src="https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460_1280.png" alt="Profile Picture">
<div class="content">
<h3>Zoey Bennett <a class="icons" href="#linkedin">Y</a><a class="icons" href="#git">X</a></h3>
<p><b>Graduating Year:</b> 2025</p>
<p>Hi, I’m Zoey Bennett, a fifth-year student at Drexel University majoring in Computer Security, with a focus on user interaction design. My passion lies in creating secure, seamless, and user-friendly online experiences.
<br><br>Beyond coding, I’m a writer at heart. I primarily blog about different stages of my life, sharing personal insights and reflections. Recently, I’ve been exploring short story writing, and I’m currently working on a piece called Rat King. It’s still in its early stages, but I’m excited to see where it leads and share it soon.</p>
<p><b>Post Graduation Plan:</b></p>
<p>After graduation, I plan to dive into the world of web development, blending my technical expertise with my love for intuitive design.</p>
</div>
</div>
<div class="profile">
<img src="https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460_1280.png" alt="Profile Picture">
<div class="content">
<h3>Phoi Luong <span class="icons">X Y</span></h3>
<p><b>Graduating Year:</b> 2026</p>
<p>Hi I’m Phoi Luong, a fourth-year student at Drexel University majoring in Computer Security. While my studies focus on cybersecurity, my true passion lies in information technology.
<br><br>
</p>
<p><b>Post Graduation Plan:</b></p>
<p>After graduation, my goal is to promote cyber awareness and empower individuals with the knowledge to stay safe in an increasingly digital world.</p>
</div>
</div>
</div>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>SecureScan</title>
<style>
body {
background-color: white;
margin: 0;
padding: 0;
font-family: 'Inter', sans-serif;
}
nav {
display: flex;
justify-content: flex-end;
background-color: white;
padding: 15px 60px;
}
nav a {
margin: 0px 20px;
text-decoration: none;
color: black;
}
.section {
background-color: #8FA4CE;
background: url(https://img.freepik.com/free-vector/gradient-network-connection-background_23-2148874050.jpg) no-repeat center center/cover;
text-align: center;
padding: 30px;
color: white;
}
.section h1 {
font-family: 'IBM Plex Mono', monospace;
}
.container {
width: 80%;
margin: 20px auto;
}
.container h3 {
font-family: 'IBM Plex Mono', monospace;
}
.form-box {
background: rgba(255, 255, 255, 0.2);
padding: 30px;
border-radius: 10px;
text-align: center;
backdrop-filter: blur(10px);
}
.form-box input {
width: 80%;
padding: 10px;
margin: 10px 0;
}
.form-box button {
padding: 10px 20px;
border: none;
background: rgb(44, 44, 124);
color: white;
cursor: pointer;
}
.upload-btn {
display: block;
margin: 10px auto;
padding: 10px;
background: lightblue;
cursor: pointer;
border: none;
}
.file-list ul {
list-style: none;
padding: 0;
}
.file-list li {
background: rgba(0, 0, 0, 0.1);
padding: 5px;
margin: 5px 0;
border-radius: 5px;
}
</style>
</head>
<body>
<nav>
<a href="about">About</a>
<a href="#learn">Learn</a>
<a href="#github">Github</a>
</nav>
<div class="section">
<div class="form-box">
<h2>SecureScan</h2>
<p>Lorem ipsum dolor amet, consectetur adipiscing elit</p>
<input type="text" placeholder="Enter text here">
<button>Enter</button>
<input type="file" id="file-upload" style="display: none;" multiple>
<button class="upload-btn" onclick="document.getElementById('file-upload').click();">Upload file(s)</button>
<div class="file-list">
<h4>Uploaded Files:</h4>
<ul id="file-list"></ul>
</div>
</div>
</div>
<div class="container">
<h2>What is Secure Scan?</h2>
<p>SecureScan is a powerful and user-friendly platform designed to help you scan files and URLs, ensuring they are safe before you open or interact with them. In today's digital age, cyber threats are more sophisticated than ever, and malicious files or links can lead to data breaches, identity theft, or system damage. Our goal is to provide an easy and effective way for users to analyze potentially harmful content and make informed decisions about their security.</p>
<h2>Learn More</h2>
<p>Lorem ipsum odor amet, consectetur adipiscing elit. Elit mi pulvinar dictum eget diam fermentum dapibus gravida magnis. Pellentesque nec ad ipsum viverra aptent. Cubilia malesuada justo sagittis dapibus ipsum hendrerit natoque nulla habitant. Et velit hendrerit integer duis hac. Tempor ligula sit pellentesque ut sit velit? Etiam rhoncus a diam malesuada molestie euismod maecenas consequat.</p>
<button class="button">More</button>
</div>
<script>
document.getElementById('file-upload').addEventListener('change', function(event) {
const fileList = document.getElementById('file-list');
fileList.innerHTML = '';
for (const file of event.target.files) {
let li = document.createElement('li');
li.textContent = file.name;
fileList.appendChild(li);
}
});
</script>
</body>
</html>
\ No newline at end of file
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Learn</title>
<style>
body {
background-color: white;
margin: 0;
padding: 0;
font-family: 'Inter', sans-serif;
}
nav {
display: flex;
justify-content: flex-end;
background-color: white;
padding: 15px 60px;
}
nav a {
margin: 0px 20px;
text-decoration: none;
color: black;
}
.about_section {
background-color: #8FA4CE;
text-align: center;
padding: 30px;
color: white;
}
.about_section h1 {
font-family: 'IBM Plex Mono', monospace;
}
.container {
width: 80%;
margin: 20px auto;
}
.container h3 {
font-family: 'IBM Plex Mono', monospace;
}
</style>
</head>
<body>
<nav>
<a href="about.html">About</a>
<a href="learn.html">Learn</a>
<a href="https://github.com/Skytex11/SeniorDesign">Github</a>
</nav>
<div class="about_section">
<h1>LEARN</h1>
<p>GOAL/PHISING INFO</p>
</div>
<div class="container">
<h3>What is Phising</h3>
<a>info on phising</a>
<br>
<h3>How to Identify Scams</h3>
<a>ways to identify scams</a>
<br>
<h3>How to Protect Yourself</h3>
<a>security measures</a>
</div>
</body>
</html>
\ No newline at end of file
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Results</title>
<link rel="stylesheet" href="/CSS/base.css">
</head>
<body>
</body>
</html>
\ No newline at end of file
const express = require('express');
const multer = require('multer');
const axios = require('axios');
const cors = require('cors');
require('dotenv').config();
const app = express();
const PORT = process.env.PORT || 5000; ///change when you want for local
const apiKey = process.env.VIRUSTOTAL_API_KEY;
if (!apiKey) {
console.error('Missing VirusTotal API key! Check your .env file.');
process.exit(1);
}
console.log('VirusTotal API Key loaded successfully');
app.use(cors());
app.use(express.json());
const pool = require('./db');
const storage = multer.memoryStorage();
const upload = multer({ storage });
app.use(express.static('public_html')); // Serves static files
// VirusTotal URLs
const FILE_SCAN_URL = 'https://www.virustotal.com/vtapi/v2/file/scan';
const URL_SCAN_URL = 'https://www.virustotal.com/vtapi/v2/url/scan';
const URL_REPORT_URL = 'https://www.virustotal.com/vtapi/v2/url/report';
const FILE_REPORT_URL = 'https://www.virustotal.com/vtapi/v2/file/report';
// Root route
app.get('/', (req, res) => {
res.sendFile(__dirname + '/public_html/index.html');
});
// Scan URL
app.post('/scan-url', async (req, res) => {
const { url } = req.body;
if (!url) return res.status(400).json({ error: 'URL is required' });
try {
const response = await axios.post(URL_SCAN_URL, null, {
params: {
apikey: process.env.VIRUSTOTAL_API_KEY,
url: url,
},
});
res.json(response.data);
} catch (error) {
console.error('Error scanning URL:', error);
res.status(500).json({ error: 'Error scanning URL' });
}
});
// Route: Scan File
app.post('/scan-file', upload.single('file'), async (req, res) => {
if (!req.file) return res.status(400).json({ error: 'File is required' });
try {
const response = await axios.post(FILE_SCAN_URL, req.file.buffer, {
params: {
apikey: process.env.VIRUSTOTAL_API_KEY,
},
headers: {
'Content-Type': 'multipart/form-data',
},
});
res.json(response.data);
} catch (error) {
console.error('Error scanning file:', error);
res.status(500).json({ error: 'Error scanning file' });
}
});
app.get('/test-db', async (req, res) => {
try {
const result = await pool.query('SELECT NOW()');
res.json({ message: 'Database connected!', time: result.rows[0] });
} catch (err) {
console.error(err);
res.status(500).json({ error: 'Database error' });
}
});
// Start server
app.listen(PORT, () => {
console.log(`Server running on http://localhost:${PORT}`);
});
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment