|
import streamlit as st |
|
import pandas as pd |
|
import subprocess |
|
|
|
|
|
data = { |
|
"Reference": ["Motlagh et al.", "Divakaran et al.", "Yao et al.", "Yigit et al.", "Coelho et al.", "Novelli et al.", "LLM4Security"], |
|
"Year": [2024, 2024, 2023, 2024, 2024, 2024, 2024], |
|
"Scope": ["Security application", "Security application", "Security application, Security of LLM", "Security application, Security of LLM", "Security application", "Security application", "Security application"], |
|
"Dimensions": ["Task", "Task", "Model, Task", "Task", "Task, Domain specific technique", "Task, Model, Domain specific technique", "Model, Task, Domain specific technique, Data"], |
|
"Time frame": ["2022-2023", "2020-2024", "2019-2024", "2020-2024", "2021-2023", "2020-2024", "2020-2024"], |
|
"Papers": ["Not specified", "Not specified", 281, "Not specified", 19, "Not specified", 127] |
|
} |
|
|
|
|
|
st.title("π LLMs for Cyber Security: State-of-the-Art Surveys") |
|
st.write("This app is based on the paper: [Large Language Models for Cyber Security](https://arxiv.org/pdf/2405.04760v3). It showcases LLMs in the cybersecurity landscape.") |
|
|
|
|
|
df = pd.DataFrame(data) |
|
st.write(df) |
|
|
|
|
|
mermaid_code = ''' |
|
graph TD; |
|
A[LLMs in Security] --> B[Security Application] |
|
B --> C[Task] |
|
B --> D[Model] |
|
D --> E[Domain-Specific Techniques] |
|
E --> F[Data] |
|
''' |
|
|
|
st.subheader("π‘οΈ Security Model Visualization with Mermaid") |
|
st.markdown(f"```mermaid\n{mermaid_code}\n```") |
|
|
|
|
|
st.markdown(""" |
|
<style> |
|
.scrollable-content { |
|
height: 200px; |
|
overflow-y: scroll; |
|
} |
|
</style> |
|
<div class="scrollable-content"> |
|
<h3>Scroll Through for More Insights:</h3> |
|
<ul> |
|
<li>2022-2023: Not specified by Motlagh et al.</li> |
|
<li>2020-2024: Yigit and Divakaran focusing on tasks and models.</li> |
|
<li>Coelho introduces domain-specific techniques from 2021 to 2023.</li> |
|
</ul> |
|
</div> |
|
""", unsafe_allow_html=True) |
|
|
|
|
|
st.subheader("π Run Python Dependency Security Audit") |
|
|
|
|
|
if st.button('Run pip-audit for Security Check'): |
|
with st.spinner('Running security audit...'): |
|
result = subprocess.run(['pip-audit'], capture_output=True, text=True) |
|
st.code(result.stdout) |
|
|
|
|
|
st.subheader("π€ AI Pair Programming: Security Recommendations") |
|
st.markdown(""" |
|
- **Reduce Code Complexity**: AI can recommend code simplification strategies. |
|
- **Minimize Attack Surface**: AI can simulate attacks and highlight vulnerable points. |
|
- **Automate Security Scans**: Use tools like `pip-audit` for continuous CVE checks. |
|
""") |
|
|
|
|
|
st.subheader("Azure Deployment Information") |
|
st.write(""" |
|
- **Azure Container Apps**: Easily deploy and scale your app with Azure Container Apps. |
|
- **Azure Container Registry**: Store and manage container images. |
|
- **Cosmos DB**: Use Cosmos DB to store security audit results and logs. |
|
""") |
|
|