Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions Server Page/Cyber_Project.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import streamlit as st


st.title("Cyber Project")
st.markdown("---")


st.header("Overview")
st.write("Redback’s Cybersecurity division comprising Infrastructure, Blue, SecDevOps, and Ethics sub-teams works collaboratively to protect the organisation’s systems, codebases, and data. This trimester, the teams are strengthening monitoring capabilities, enhancing vulnerability detection, refining automated security pipelines, and improving ethical compliance frameworks. Collectively, the sub-teams aim to uplift Redback’s overall security posture, ensure resilient infrastructure, and establish clear, maintainable processes for future cohorts. ")
st.markdown("---")
17 changes: 17 additions & 0 deletions Server Page/Network.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import streamlit as st
import subprocess
import socket
import re

st.title("🌐 Network")
st.markdown("---")

#Host Name
hostname = socket.gethostname()
st.header("🖥️ Hostname")
st.code(hostname)

# Ip
ip_address = socket.gethostbyname(hostname)
st.header("📡 Local IP Address")
st.code(ip_address)
90 changes: 90 additions & 0 deletions Server Page/Ports.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
import streamlit as st
import socket
import pandas as pd
from typing import List, Tuple

# Try psutil (best method)
try:
import psutil
except ImportError:
psutil = None

#--------------------------------------------------------------
# Page setup
#--------------------------------------------------------------
st.set_page_config(page_title="Open Ports Viewer", layout="wide")
st.title("🔓 Open Ports")
st.markdown("Automatically showing all listening TCP/UDP ports on this machine.")

#--------------------------------------------------------------
# Helper: Convert rows into DataFrame
#--------------------------------------------------------------
def human_ports_df(rows: List[Tuple]) -> pd.DataFrame:
# Removed PID column from the table
return pd.DataFrame(rows, columns=["Protocol", "Local IP", "Port", "Process"])

#--------------------------------------------------------------
# Method 1: psutil listing
#--------------------------------------------------------------
def list_open_ports_psutil():
rows = []
for c in psutil.net_connections(kind="inet"):
if hasattr(c, "status") and c.status != psutil.CONN_LISTEN:
continue
if not c.laddr:
continue

ip = getattr(c.laddr, "ip", c.laddr[0])
port = getattr(c.laddr, "port", c.laddr[1])
proto = "TCP" if c.type == socket.SOCK_STREAM else "UDP"
pid = c.pid or None

# Resolve process name only (no PID)
pname = "-"
if pid:
try:
pname = psutil.Process(pid).name()
except:
pname = "-"

# No PID added to the row
rows.append((proto, ip, port, pname))

return human_ports_df(rows)

#--------------------------------------------------------------
# Method 2: netstat fallback (Windows)
#--------------------------------------------------------------
def list_open_ports_netstat():
import subprocess, re
try:
output = subprocess.check_output(["netstat", "-ano"], text=True)
except:
return pd.DataFrame(columns=["Protocol", "Local IP", "Port", "Process"])

rows = []
for line in output.splitlines():
match = re.search(r"^(TCP|UDP)\s+(\S+):(\d+)\s+.*LISTENING\s+(\d+)", line, re.I)
if match:
proto, ip, port, _pid = match.groups()
rows.append((proto, ip, int(port), "-")) # No PID kept

return human_ports_df(rows)

#--------------------------------------------------------------
# Select method & display
#--------------------------------------------------------------
if psutil:
df = list_open_ports_psutil()
else:
df = list_open_ports_netstat()

df = df.sort_values(["Protocol", "Port"]).reset_index(drop=True)

if df.empty:
st.info("No open ports detected or missing permissions.")
else:
st.success(f"Found {len(df)} listening ports:")

# Full page table, scrolls with the page
st.table(df)
25 changes: 25 additions & 0 deletions Server Page/Project_1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import streamlit as st


st.title("Project 1")
st.markdown("---")

st.header("Overview")
st.write("The Smart Bike VR project aims to transform indoor cycling into an immersive experience by blending virtual gamified challenges with real-time health and performance tracking. While the project has strong foundations from previous trimesters, it is currently inactive due to the team being unresponsive at this early stage. Despite the temporary pause, the project is expected to resume once the team re-engages in the coming weeks, allowing development to progress alongside Redback’s broader ecosystem initiatives. ")
st.markdown("---")

st.header("Project Goals T3 2025")
st.write("1. Create an immersive VR cycling environment that responds naturally to user movement. ")
st.write("2. Integrate hardware sensors (speed, cadence, distance) with the VR system for accurate real-time tracking.")
st.write("3. Design engaging gamified challenges to improve user motivation and consistency. ")
st.write("4. Ensure reliability and safety through VR design best practices and user-friendly controls. ")
st.write("5. Produce a functional prototype that demonstrates Redback’s vision for next-generation fitness technology. ")

st.markdown("---")
st.header("T3 2025 Team")
st.write("Anshpreet singh sapra (Junior)")
st.write("MITHUN MEERA SAKTHIVEL (Senior)")
st.write("SHRIJITH NANDAGOPAL (Senior)")
st.write("YEHEZKIEL GAYUH PRIYONO (Junior)")
st.write("SHI CHEN (Junior)")
st.write("ANJOLIE SUSAN PHILIP (Junior)")
8 changes: 8 additions & 0 deletions Server Page/SSH.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import streamlit as st
import psutil
import datetime

st.title("🔐 SSH Connections")
st.markdown("---")


22 changes: 22 additions & 0 deletions Server Page/ServerInfo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import streamlit as st
import psutil
import datetime

st.title("🗄️ Server Info")
st.markdown("---")

boot_time_timestamp = psutil.boot_time()
boot_time = datetime.datetime.fromtimestamp(boot_time_timestamp)

now = datetime.datetime.now()
uptime = now - boot_time

st.subheader("🖥 PC/Server Boot Time:")
st.write(boot_time.strftime("%Y-%m-%d %H:%M:%S"))
st.markdown("---")
st.subheader("⏱ Current Uptime:")
days = uptime.days
hours, remainder = divmod(uptime.seconds, 3600)
minutes, seconds = divmod(remainder, 60)
st.write(f"**{days} days, {hours} hours, {minutes} minutes, {seconds} seconds**")
st.markdown("---")
37 changes: 37 additions & 0 deletions Server Page/Storage.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import streamlit as st, os, shutil

try:
import psutil
except ImportError:
psutil = None

st.title("💾 Local Storage")
st.markdown("---")
def human_bytes(n):
for unit in ["B","KB","MB","GB","TB","PB"]:
if abs(n) < 1024: return f"{n:3.1f} {unit}"
n /= 1024
return f"{n:.1f} EB"

disks = []
if psutil:
for part in psutil.disk_partitions(all=False):
try:
u = psutil.disk_usage(part.mountpoint)
disks.append((part.mountpoint, u.used, u.total))
except Exception:
pass
else:
for letter in "CDEFGHIJKLMNOPQRSTUVWXYZ":
path = f"{letter}:/"
if os.path.exists(path):
t,u,f = shutil.disk_usage(path)
disks.append((path, u, t))

if not disks:
st.warning("No disk info found.")
else:
for mount, used, total in disks:
pct = (used/total*100) if total else 0
st.write(f"**{mount}** — {pct:.1f}% used ({human_bytes(used)} / {human_bytes(total)})")
st.progress(int(pct))
19 changes: 19 additions & 0 deletions Server Page/Training.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import streamlit as st

st.set_page_config(page_title="Security Training", layout="wide")
st.title("🔐 Security Training")
st.markdown("---")
st.components.v1.iframe(
"https://d2l.deakin.edu.au/d2l/le/discovery/view/course/1603088",
height=600,
scrolling=False
)









Loading