Metadata-Version: 2.4
Name: seclog-lite
Version: 0.3.0
Summary: Offline SSH authentication log analysis
License-Expression: MIT
Project-URL: Repository, https://github.com/sharveshnagarajan/seclog-lite
Project-URL: Issues, https://github.com/sharveshnagarajan/seclog-lite/issues
Keywords: ssh,security,log-analysis,soc
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: license-file

# SecLog Lite

[![CI](https://github.com/sharveshnagarajan/seclog-lite/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/sharveshnagarajan/seclog-lite/actions/workflows/ci.yml)
[![PyPI](https://img.shields.io/pypi/v/seclog-lite)](https://pypi.org/project/seclog-lite/)
[![Python](https://img.shields.io/badge/python-3.10%2B-blue)](https://pypi.org/project/seclog-lite/)
[![License](https://img.shields.io/badge/license-MIT-green)](LICENSE)

Lightweight, dependency-free Python toolkit for offline
SSH security log analysis and threat detection.

## Overview

SecLog Lite helps cybersecurity students, developers,
system administrators and security analysts identify
suspicious authentication activity in SSH logs.

All analysis runs locally without cloud services,
external APIs or third-party runtime dependencies.

## Features

- SSH brute-force detection
- Potential password spraying detection
- Invalid account probing detection
- Successful login after repeated failures
- IPv4 and IPv6 support
- Configurable detection thresholds
- MITRE ATT&CK mappings
- JSON, CSV, text and HTML reports
- Offline security reporting dashboard

## Installation

Python 3.10 or later is required.

Install the published package from PyPI:

    python3 -m pip install seclog-lite

For local development, from the project directory:

    python3 -m pip install -e .

## Quick Start

    seclog sample.log

Generate a JSON report:

    seclog sample.log --format json

Generate a CSV report:

    seclog sample.log --format csv

Generate an HTML dashboard:

    seclog sample.log --format html > report.html

Customize detection:

    seclog sample.log --threshold 5 --window 300

For v0.3.0 development builds, standard input is supported:

    cat sample.log | seclog - --format json

## Security Dashboard

Generate a self-contained HTML report from an authorized SSH log:

```bash
seclog sample.log --format html > report.html
```

Open `report.html` in a browser to review severity counts, suspicious IP addresses, detection rules, and MITRE ATT&CK mappings.

![SecLog Lite HTML security dashboard showing two alerts from synthetic SSH authentication logs](docs/images/dashboard.png)

*Example dashboard generated from synthetic test logs using documentation-only IP addresses. Alerts are heuristic indicators, not confirmation of compromise.*

## Detection Rules

| Rule | MITRE ATT&CK |
| --- | --- |
| Repeated SSH failures | T1110.001 |
| Possible password spraying | T1110.003 |
| Invalid account probing | T1110 |
| Success after failures | T1110.001 |

## Testing

    python3 -m unittest discover -s tests -v

## Privacy

SecLog Lite processes logs locally.
No telemetry or external data transmission is required.

## Limitations

Supports traditional SSH authentication logs and, in the upcoming v0.3.0, ISO 8601 timestamps. Offset-aware timestamps are normalized to UTC; timestamps without offsets are assumed to use the same time basis. Mixed local time zones and traditional year rollover are not inferred.
Detection rules are heuristic indicators and do not
confirm that an attack or compromise has occurred.

Analyze only logs you are authorized to access.

## Roadmap

- Additional Linux log formats
- Real-time log monitoring
- Improved threat analytics
- Configurable detection rules
- Expanded packaging and automated releases
- Community-driven improvements

## Project Status

Early-stage public project. Contributions and feedback are welcome.

- [Source code](https://github.com/sharveshnagarajan/seclog-lite)
- [PyPI package](https://pypi.org/project/seclog-lite/)
- [Release v0.2.0](https://github.com/sharveshnagarajan/seclog-lite/releases/tag/v0.2.0)
