# adhilbinmujeeb/mas_course_project-team- architecture

> Architecture diagram of the GitHub repository adhilbinmujeeb/mas_course_project-team-, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/adhilbinmujeeb/mas_course_project-team-
- Repository: https://github.com/adhilbinmujeeb/mas_course_project-team-

## Overview

This repository statically analyzes Android APKs (never installs or executes them), then presents explainable, app-category-aware risk assessments through a CLI and Flask dashboard. The primary workflow is APK intake and parsing, DEX feature extraction, normalization, contextual scoring, and HTML reporting; existing analysis JSON can also enter through the dashboard or CLI. The graph preserves documented extraction and category capabilities, but several orchestration details are unsampled, so uncertain call links are omitted.

Main entry points: [`pipeline.py`](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/pipeline.py) (CLI Pipeline), [`anzal_android-malware-framework/android-malware-framework/app.py`](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/app.py) (Flask Dashboard), [`feature_extraction/apk_loader.py`](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/apk_loader.py) (DEX Loader), [`anzal_android-malware-framework/android-malware-framework/report_generator.py`](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/report_generator.py) (Report Builder)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_intake["APK Intake"]
  node_pipeline["CLI Pipeline<br/>[pipeline.py]"]
  node_parser["APK Parser<br/>[apk_parser.py]"]
end

subgraph group_analysis["Static Analysis"]
  node_loader["DEX Loader<br/>[apk_loader.py]"]
  node_api_scan["Sensitive API Scan<br/>[sensitive_apis.py]"]
  node_string_scan["String Scan"]
  node_obfuscation["Obfuscation Checks"]
  node_analyzer["Feature Normalizer<br/>[analyzer.py]"]
end

subgraph group_assessment["Risk Assessment"]
  node_category["Category Context<br/>[app_category.py]"]
  node_scoring["Risk Scoring<br/>[scoring_engine.py]"]
end

subgraph group_delivery["User Delivery"]
  node_reportgen["Report Builder"]
  node_dashboard["Flask Dashboard<br/>[app.py]"]
  node_templates["Report Views"]
  node_charting["Dashboard Charts<br/>[dashboard.js]"]
  node_reports["Saved Reports"]
end

node_user(("Analyst"))
node_apk["APK or JSON"]
node_androguard["Androguard"]

node_user -->|"runs scan"| node_pipeline
node_user -->|"uploads file"| node_dashboard
node_apk -->|"provides input"| node_pipeline
node_pipeline -->|"parses archive"| node_parser
node_pipeline -->|"loads DEX"| node_loader
node_loader -->|"uses parser"| node_androguard
node_api_scan -->|"reads analysis"| node_loader
node_string_scan -->|"reads DEX"| node_loader
node_obfuscation -->|"reads analysis"| node_loader
node_pipeline -->|"extracts API hits"| node_api_scan
node_pipeline -->|"extracts strings"| node_string_scan
node_pipeline -->|"checks obfuscation"| node_obfuscation
node_pipeline -->|"normalizes findings"| node_analyzer
node_pipeline -->|"scores features"| node_scoring
node_analyzer -->|"resolves context"| node_category
node_scoring -->|"uses tiers"| node_category
node_dashboard -->|"builds features"| node_analyzer
node_dashboard -->|"calculates risk"| node_scoring
node_dashboard -->|"requests report"| node_reportgen
node_reportgen -->|"renders view"| node_templates
node_reportgen -->|"saves report"| node_reports
node_dashboard -->|"renders dashboard"| node_templates
node_templates -->|"embeds chart data"| node_charting
node_dashboard -->|"shows assessment"| node_user

click node_pipeline "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/pipeline.py"
click node_parser "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/apk_parser.py"
click node_loader "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/apk_loader.py"
click node_api_scan "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/sensitive_apis.py"
click node_string_scan "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/string_extraction.py"
click node_obfuscation "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/obfuscation_heuristics.py"
click node_analyzer "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/analyzer.py"
click node_category "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/app_category.py"
click node_scoring "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/scoring_engine.py"
click node_reportgen "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/report_generator.py"
click node_dashboard "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/app.py"
click node_templates "https://github.com/adhilbinmujeeb/mas_course_project-team-/tree/main/anzal_android-malware-framework/android-malware-framework/templates"
click node_charting "https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/static/js/dashboard.js"
click node_reports "https://github.com/adhilbinmujeeb/mas_course_project-team-/tree/main/anzal_android-malware-framework/android-malware-framework/reports"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_pipeline,node_parser toneBlue
class node_loader,node_api_scan,node_string_scan,node_obfuscation,node_analyzer toneAmber
class node_category,node_scoring toneMint
class node_reportgen,node_dashboard,node_templates,node_charting,node_reports toneRose
class node_user,node_apk,node_androguard toneIndigo
```

## Components

### APK Intake

- [CLI Pipeline](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/pipeline.py): `pipeline.py`
- [APK Parser](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/apk_parser.py): `apk_parser.py`

### Static Analysis

- [DEX Loader](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/apk_loader.py): `feature_extraction/apk_loader.py`
- [Sensitive API Scan](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/sensitive_apis.py): `feature_extraction/sensitive_apis.py`
- [String Scan](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/string_extraction.py): `feature_extraction/string_extraction.py`
- [Obfuscation Checks](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/feature_extraction/obfuscation_heuristics.py): `feature_extraction/obfuscation_heuristics.py`
- [Feature Normalizer](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/analyzer.py): `anzal_android-malware-framework/android-malware-framework/analyzer.py`

### Risk Assessment

- [Category Context](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/app_category.py): `anzal_android-malware-framework/android-malware-framework/app_category.py`
- [Risk Scoring](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/scoring_engine.py): `anzal_android-malware-framework/android-malware-framework/scoring_engine.py`

### User Delivery

- [Report Builder](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/report_generator.py): `anzal_android-malware-framework/android-malware-framework/report_generator.py`
- [Flask Dashboard](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/app.py): `anzal_android-malware-framework/android-malware-framework/app.py`
- [Report Views](https://github.com/adhilbinmujeeb/mas_course_project-team-/tree/main/anzal_android-malware-framework/android-malware-framework/templates): `anzal_android-malware-framework/android-malware-framework/templates`
- [Dashboard Charts](https://github.com/adhilbinmujeeb/mas_course_project-team-/blob/main/anzal_android-malware-framework/android-malware-framework/static/js/dashboard.js): `anzal_android-malware-framework/android-malware-framework/static/js/dashboard.js`
- [Saved Reports](https://github.com/adhilbinmujeeb/mas_course_project-team-/tree/main/anzal_android-malware-framework/android-malware-framework/reports): `anzal_android-malware-framework/android-malware-framework/reports`

### Other components

- **Analyst**
- **APK or JSON**
- **Androguard**

## Connections

- Analyst → CLI Pipeline: runs scan
- Analyst → Flask Dashboard: uploads file
- APK or JSON → CLI Pipeline: provides input
- CLI Pipeline → APK Parser: parses archive
- CLI Pipeline → DEX Loader: loads DEX
- DEX Loader → Androguard: uses parser
- Sensitive API Scan → DEX Loader: reads analysis
- String Scan → DEX Loader: reads DEX
- Obfuscation Checks → DEX Loader: reads analysis
- CLI Pipeline → Sensitive API Scan: extracts API hits
- CLI Pipeline → String Scan: extracts strings
- CLI Pipeline → Obfuscation Checks: checks obfuscation
- CLI Pipeline → Feature Normalizer: normalizes findings
- CLI Pipeline → Risk Scoring: scores features
- Feature Normalizer → Category Context: resolves context
- Risk Scoring → Category Context: uses tiers
- Flask Dashboard → Feature Normalizer: builds features
- Flask Dashboard → Risk Scoring: calculates risk
- Flask Dashboard → Report Builder: requests report
- Report Builder → Report Views: renders view
- Report Builder → Saved Reports: saves report
- Flask Dashboard → Report Views: renders dashboard
- Report Views → Dashboard Charts: embeds chart data
- Flask Dashboard → Analyst: shows assessment
