PHPackages                             artisanpack-ui/security-analytics - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. artisanpack-ui/security-analytics

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

artisanpack-ui/security-analytics
=================================

Security analytics for Laravel — security event logging, anomaly detection, threat intelligence, SIEM export (Splunk, Datadog, Elasticsearch, syslog), incident response, alerting, and dashboards.

1.0.1(1mo ago)073[2 issues](https://github.com/ArtisanPack-UI/security-analytics/issues)1MITPHPPHP ^8.2CI passing

Since May 19Pushed 1mo agoCompare

[ Source](https://github.com/ArtisanPack-UI/security-analytics)[ Packagist](https://packagist.org/packages/artisanpack-ui/security-analytics)[ RSS](/packages/artisanpack-ui-security-analytics/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (2)Dependencies (22)Versions (4)Used By (1)

ArtisanPack UI — Security Analytics
===================================

[](#artisanpack-ui--security-analytics)

Security analytics for Laravel: structured security event logging, pluggable anomaly detection, threat intelligence aggregation, SIEM export (Datadog / Elasticsearch / Splunk / Syslog / Webhook), playbook-driven incident response automation, multi-channel alerting, reports, and a Livewire dashboard.

This package is part of the **ArtisanPack UI Security 2.0** split — the analytics, monitoring, and incident-response features previously bundled inside `artisanpack-ui/security` (1.x) live here in 2.0+.

Features
--------

[](#features)

- **Event logging** — `SecurityEventLogger` plus a `LogAuthenticationEvents` listener that captures Laravel auth events automatically into a structured `security_events` table.
- **Anomaly detection** — 8 pluggable detectors (`BruteForce`, `CredentialStuffing`, `GeoVelocity`, `PrivilegeEscalation`, `AccessPattern`, `Behavioral`, `Statistical`, `RuleBased`) orchestrated by `AnomalyDetectionService` with per-user baselines via `BaselineManager`.
- **Threat intelligence** — 5 pluggable providers (`AbuseIPDB`, `GoogleSafeBrowsing`, `IpQualityScore`, `VirusTotal`, `CustomFeed`) aggregated by `ThreatIntelligenceService`.
- **SIEM export** — 5 pluggable exporters (`Datadog`, `Elasticsearch`, `Splunk`, `Syslog`, `Webhook`) backed by `SiemExportService`.
- **Incident response automation** — 10 pluggable actions (block IP / user, lock account, revoke sessions, force password reset, require 2FA, terminate session, notify admin, rate-limit IP, enable enhanced logging, log event) coordinated by `IncidentResponder` and driven by `ResponsePlaybook` definitions.
- **Alerting** — 8 channels (`Database`, `Email`, `OpsGenie`, `PagerDuty`, `Slack`, `Sms`, `Teams`, `Webhook`) routed via `AlertManager` with `AlertRule` definitions and `AlertHistory` audit.
- **Reports** — 6 report types (`ExecutiveSummary`, `Incident`, `Compliance`, `Threat`, `Trend`, `UserActivity`) generated on-demand or on a schedule via `ScheduledReport`.
- **Dashboard** — bundled `SecurityDashboardController` (10 JSON endpoints) plus 4 Livewire components (`SecurityDashboard`, `SecurityEventList`, `SecurityStats`, `SuspiciousActivityList`) with shipped Blade views.
- **Eloquent models** (11), migrations (10), and factories (9) for the full schema.
- **Console commands** (11) for processing, pruning, exporting, generating reports, syncing threat feeds, and updating behavior baselines.
- **Background jobs** (5) for off-request analysis, SIEM export, scheduled reports, metric processing, and alert delivery.
- **Events** (3) — `SecurityEventOccurred`, `AnomalyDetected`, `SuspiciousActivityDetected` — subscribe to integrate with downstream systems.
- `SecurityAnalytics` Facade + `security_analytics()` helper.

Installation
------------

[](#installation)

```
composer require artisanpack-ui/security-analytics
php artisan migrate
```

(Optional) Publish the config:

```
php artisan vendor:publish --tag=security-analytics-config
```

Quick start
-----------

[](#quick-start)

Log a security event:

```
use ArtisanPackUI\SecurityAnalytics\Facades\SecurityAnalytics;

security_analytics()->logger()->log(
    type: 'authentication',
    name: 'login.failed',
    severity: 'warning',
    context: ['username' => $request->input('email')],
);
```

Or react to the auth events Laravel fires:

```
// The package's LogAuthenticationEvents listener wires this up automatically.
// To opt out, set config('artisanpack.security-analytics.auto_log_auth_events') to false.
```

Mount the dashboard:

```
// The dashboard routes auto-register under the configured prefix (default: /security).
// Visit /security/dashboard to see the Livewire UI.
```

Dashboard Blade views
---------------------

[](#dashboard-blade-views)

The dashboard views ship as plain HTML + Tailwind by design — the package does not depend on `artisanpack-ui/livewire-ui-components`. To customize them, shadow the package views by placing your own files at `resources/views/vendor/security-analytics/livewire/*.blade.php` — Laravel resolves overrides before package defaults.

Documentation
-------------

[](#documentation)

- [Documentation home](docs/home.md)
- [Getting started](docs/getting-started.md)
- [Installation](docs/installation.md)
- [Usage](docs/usage.md)
- [Advanced](docs/advanced.md)
- [FAQ](docs/faq.md)
- [Troubleshooting](docs/troubleshooting.md)
- [Changelog](CHANGELOG.md)

Requirements
------------

[](#requirements)

- PHP 8.2+
- Laravel 10 / 11 / 12
- Laravel 13 (requires PHP 8.3+)
- `livewire/livewire` ^3.6 or ^4.0 (only required for the dashboard UI; the rest of the package works without Livewire)

Sibling packages
----------------

[](#sibling-packages)

PackageScope[`artisanpack-ui/security-full`](https://github.com/ArtisanPack-UI/security-full)Meta-package — pulls in the full security suite (all six packages below) in a single require[`artisanpack-ui/security`](https://github.com/ArtisanPack-UI/security)Core: input sanitization, escaping, CSP, security headers[`artisanpack-ui/security-auth`](https://github.com/ArtisanPack-UI/security-auth)2FA, password complexity, account lockout, sessions[`artisanpack-ui/security-advanced-auth`](https://github.com/ArtisanPack-UI/security-advanced-auth)WebAuthn, SSO, social login[`artisanpack-ui/rbac`](https://github.com/ArtisanPack-UI/rbac)Roles, permissions, Gate integration[`artisanpack-ui/secure-uploads`](https://github.com/ArtisanPack-UI/secure-uploads)File validation, malware scanning, signed-URL serving[`artisanpack-ui/compliance`](https://github.com/ArtisanPack-UI/compliance)GDPR / CCPA / LGPD compliance toolsLicense
-------

[](#license)

MIT — see [LICENSE](LICENSE).

Contributing
------------

[](#contributing)

Please read the [contributing guidelines](CONTRIBUTING.md) before opening an issue or PR.

###  Health Score

43

—

FairBetter than 89% of packages

Maintenance92

Actively maintained with recent releases

Popularity13

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~26 days

Total

2

Last Release

40d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ba2a2c40c9a93470595cd10701d2291434f3a7db61862d9700a9e69e31608c6c?d=identicon)[JacobMartellaWebDesign](/maintainers/JacobMartellaWebDesign)

---

Top Contributors

[![ViewFromTheBox](https://avatars.githubusercontent.com/u/8247489?v=4)](https://github.com/ViewFromTheBox "ViewFromTheBox (30 commits)")

---

Tags

laravelmonitoringsecurityanalyticsanomaly-detectionSIEMaudit-logthreat-intelligenceincident-response

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/artisanpack-ui-security-analytics/health.svg)

```
[![Health](https://phpackages.com/badges/artisanpack-ui-security-analytics/health.svg)](https://phpackages.com/packages/artisanpack-ui-security-analytics)
```

###  Alternatives

[muhammadsadeeq/laravel-activitylog-ui

A beautiful, modern UI for Spatie's Activity Log with advanced filtering, analytics, and real-time features.

17717.0k](/packages/muhammadsadeeq-laravel-activitylog-ui)[spatie/laravel-flare

Send Laravel errors to Flare

111.4M7](/packages/spatie-laravel-flare)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
