Skip to content

Commit

Permalink
Merge pull request #54 from userjack6880/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
userjack6880 authored Jul 27, 2022
2 parents fb3499a + fea6e4e commit 34eb9b8
Show file tree
Hide file tree
Showing 16 changed files with 1,260 additions and 1,181 deletions.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Open DMARC Analyzer

This is Open DMARC Analyzer version 0 alpha-9 (0-α9) by John Bradley ([email protected]). Open DMARC Analyzer is an Open Source DMARC Report Analyzer to be used with DMARC reports that have been parsed by [John Levine's rrdmarc script](http://www.taugh.com/rddmarc/) or [techsneeze's dmarcts-report-parser](https://github.com/techsneeze/dmarcts-report-parser).
This is Open DMARC Analyzer Version 1 Feature Complete (1-fc) by John Bradley ([email protected]). Open DMARC Analyzer is an Open Source DMARC Report Analyzer to be used with DMARC reports that have been parsed by [John Levine's rrdmarc script](http://www.taugh.com/rddmarc/) or [techsneeze's dmarcts-report-parser](https://github.com/techsneeze/dmarcts-report-parser).

Open DMARC Analyzer was written because there didn't seem to be a full-featured self-hosted report analyzer that provided enough details to make heads or tails of a large volume of DMARC reports that come into medium to large-sized organizations. While other solutions required paid subscriptions or have part of it hosted on AWS, Open DMARC Analyzer will run on any webserver that supports PHP 7.4+ and MySQL 15.1+.

Expand Down Expand Up @@ -94,9 +94,10 @@ Valid date signifiers are `m`, `w`, and `d` for "month", "week", and "day".

# Latest Changes

## 0-α9
- Bugfixes
- Version Update to begin final feature implementation for Version 1 Feature Complete
## 1-fc
- Documentation Updates
- Formatting
- Feature Complete Release

See `CHANGELOG` under `docs` for full details of all changes.

Expand All @@ -119,10 +120,9 @@ Support will be provided as outlined in the following schedule. For more details

| Version | Support Level | Released | End of Support | End of Life |
| ----------------------------------- | ---------------- | -------------- | -------------- | ------------- |
| Version 0 Alpha 9.1 (future) | Full Support | TBD | TBD | TBD |
| Version 0 Alpha 9 (current) | Full Support | 2 May 2022 | TBD | TBD |
| Version 0 Alpha 8.2 | Critical Support | 31 March 2022 | 2 May 2022 | TBD |
| Version 0 Alpha 8.1 or Older | End of Life | 30 March 2022 | 31 March 2022 | 2 May 2022 |
| Version 1 Feature Complete | Full Support | 27 July 2022 | TBD | TBD |
| Version 0 Alpha 9 | Critical Support | 2 May 2022 | 27 July 2022 | TBD |
| Version 0 Alpha 8.2 or Older | End of Life | 31 March 2022 | 2 May 2022 | 27 July 2022 |

# Contributing

Expand All @@ -135,6 +135,6 @@ Primary Contributors

Thanks to [all who contributed](https://github.com/userjack6880/Open-DMARC-Analyzer/graphs/contributors) and [have given feedback](https://github.com/userjack6880/Open-DMARC-Analyzer/issues?q=is%3Aissue).

# Licenses
# Licenses and Copyrights

Open DMARC Analyzer is released under GNU GPLv3. See `LICENSE`.
Copyright © 2022 John Bradley (userjack6880). Open DMARC Analyzer is released under GNU GPLv3. See `LICENSE`.
12 changes: 9 additions & 3 deletions config.php.pub
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
<?php
/*
/* ----------------------------------------------------------------------------

Open DMARC Analyzer - Open Source DMARC Analyzer
Copyright (C) 2022 - John Bradley (userjack6880)

config.php
2022 - John Bradley (userjack6880)
configuration file

Available at: https://github.com/userjack6880/Open-DMARC-Analyzer

-------------------------------------------------------------------------------

This file is part of Open DMARC Analyzer.

Open DMARC Analyzer is free software: you can redistribute it and/or modify it under
Expand All @@ -19,7 +24,8 @@ PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with
this program. If not, see <https://www.gnu.org/licenses/>.
*/

---------------------------------------------------------------------------- */

// Database Settings

Expand Down
5 changes: 5 additions & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

## 1-fc
- Documentation Updates
- Formatting
- Feature Complete Release

## 0-α9
- Bugfixes
- Version Update to begin final feature implementation for Version 1 Feature Complete
Expand Down
6 changes: 3 additions & 3 deletions docs/SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ Open DMARC Analyzer Version Security Support

| Version | Supported | End of Life |
| -------------------------- | --------- | -------------- |
| Version 0 Alpha 9.1 | YES | TBD |
| Version 0 Alpha 9 | YES | TBD |
| Version 0 Alpha 8.2 | YES | TBD |
| Version 1 Feature Complete | YES | TBD |
| Version 0 Alpha 9 | NO | TBD |
| Version 0 Alpha 8.2 | NO | 27 July 2022 |
| Version 0 Alpha 8.1 | NO | 2 May 2022 |
| Version 0 Alpha 8 | NO | 30 March 2022 |
| Version 0 Alpha 7 or Older | NO | 29 March 2022 |
6 changes: 3 additions & 3 deletions docs/SUPPORT.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ Due to the limited time available to developrs to maintain support, dates must b

| Version | Support Level | Released | End of Support | End of Life |
| ----------------------------------- | ---------------- | -------------- | -------------- | ------------- |
| Version 0 Alpha 9.1 (future) | Full Support | TBD | TBD | TBD |
| Version 0 Alpha 9 (current) | Full Support | 2 May 2022 | TBD | TBD |
| Version 0 Alpha 8.2 | Critical Support | 31 March 2022 | 2 May 2022 | TBD |
| Version 1 Feature Complete (future) | Full Support | 27 July 2022 | TBD | TBD |
| Version 0 Alpha 9 | Critical Support | 2 May 2022 | 27 July 2022 | TBD |
| Version 0 Alpha 8.2 | End of Life | 31 March 2022 | 2 May 2022 | 27 July 2022 |
| Version 0 Alpha 8.1 | End of Life | 30 March 2022 | 31 March 2022 | 2 May 2022 |
| Version 0 Alpha 8 or Older | End of Life | 29 March 2022 | 30 March 2022 | 30 March 2022 |

Expand Down
12 changes: 9 additions & 3 deletions includes.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
<?php
/*
/* ----------------------------------------------------------------------------
Open DMARC Analyzer - Open Source DMARC Analyzer
Copyright (C) 2022 - John Bradley (userjack6880)
includes.php
2022 - John Bradley (userjack6880)
file where other includes are listed and included
Available at: https://github.com/userjack6880/Open-DMARC-Analyzer
-------------------------------------------------------------------------------
This file is part of Open DMARC Analyzer.
Open DMARC Analyzer is free software: you can redistribute it and/or modify it under
Expand All @@ -19,7 +24,8 @@
You should have received a copy of the GNU General Public License along with
this program. If not, see <https://www.gnu.org/licenses/>.
*/
---------------------------------------------------------------------------- */

include_once 'config.php';
include_once 'includes/template.php';
Expand Down
76 changes: 41 additions & 35 deletions includes/db.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
<?php
/*
Open DMARC Analyzer - Open Source DMARC Analyzer
/* ----------------------------------------------------------------------------
Open DMARC Analyzer - An Open Source DMARC Analyzer
Copyright (C) 2022 - John Bradley (userjack6880)
includes/db.php
2022 - John Bradley (userjack6880)
basic database functions
Available at: https://github.com/userjack6880/Open-DMARC-Analyzer
-------------------------------------------------------------------------------
This file is part of Open DMARC Analyzer.
Open DMARC Analyzer is free software: you can redistribute it and/or modify it under
Expand All @@ -19,51 +24,52 @@
You should have received a copy of the GNU General Public License along with
this program. If not, see <https://www.gnu.org/licenses/>.
*/
---------------------------------------------------------------------------- */

// Connect to DB //
function dbConn() {
try {
$pdo = new PDO("mysql:host=".DB_HOST.";dbname=".DB_NAME.";port=".DB_PORT, DB_USER, DB_PASS);
}
catch (PDOException $e) {
echo 'Connection failed: '.$e->getMessage();
}
return $pdo;
try {
$pdo = new PDO("mysql:host=".DB_HOST.";dbname=".DB_NAME.";port=".DB_PORT, DB_USER, DB_PASS);
}
catch (PDOException $e) {
echo 'Connection failed: '.$e->getMessage();
}
return $pdo;
}

// Perform a Query
function dbQuery($pdo, $statement, $params) {
if(!isset($statement)) {
echo "No query statement given!";
die;
}
else {
try {
$query = $pdo->prepare($statement);
if (isset($params)) {
$query->execute($params);
}
else {
$query->execute();
}
if(!isset($statement)) {
echo "No query statement given!";
die;
}
else {
try {
$query = $pdo->prepare($statement);
if (isset($params)) {
$query->execute($params);
}
else {
$query->execute();
}
if($query->errorCode() != 0) {
$errors = $query->errorInfo();
echo " failed: ".$errors[2]."<br>";
exit();
}
}
catch (PDOException $e) {
echo 'Could not perform query: '.$e->getMessage();
}
}
catch (PDOException $e) {
echo 'Could not perform query: '.$e->getMessage();
}

$rows = [];
$rows = [];

while ($row = $query->fetch(PDO::FETCH_ASSOC)) {
array_push($rows, $row);
}
$query = null;
return $rows;
}
while ($row = $query->fetch(PDO::FETCH_ASSOC)) {
array_push($rows, $row);
}
$query = null;
return $rows;
}
}
?>
Loading

0 comments on commit 34eb9b8

Please sign in to comment.