- Prepping to begin the firewall module
This commit is contained in:
parent
a5f305fb7f
commit
e78ee3a458
|
@ -21,7 +21,8 @@
|
||||||
"lean" : {
|
"lean" : {
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"definitions" : [
|
"definitions" : [
|
||||||
"meta/definitions/software.php"
|
"meta/definitions/software.php",
|
||||||
|
"meta/definitions/storage.php"
|
||||||
],
|
],
|
||||||
"config": [
|
"config": [
|
||||||
"meta/config.php"
|
"meta/config.php"
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
use Psr\Container\ContainerInterface;
|
||||||
|
|
||||||
|
use Ulmus\ConnectionAdapter,
|
||||||
|
Ulmus\Container\AdapterProxy;
|
||||||
|
|
||||||
|
use Storage\Session;
|
||||||
|
|
||||||
|
use function DI\autowire, DI\create, DI\get;
|
||||||
|
|
||||||
|
return [
|
||||||
|
'console.adapter' => function($c) {
|
||||||
|
$adapter = new ConnectionAdapter('sqlite', $c->get('config')['ulmus'], true);
|
||||||
|
$adapter->resolveConfiguration();
|
||||||
|
|
||||||
|
return $adapter;
|
||||||
|
}
|
||||||
|
];
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Lean\Console\Controller;
|
||||||
|
|
||||||
|
class Firewall
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,24 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Lean\Console\Entity\Firewall;
|
||||||
|
|
||||||
|
use Ulmus\Attribute\Obj\Table;
|
||||||
|
use Ulmus\Attribute\Property\Field;
|
||||||
|
|
||||||
|
#[Table(adapter: "lean.console")]
|
||||||
|
class Connection
|
||||||
|
{
|
||||||
|
#[Field\Id]
|
||||||
|
public string $id;
|
||||||
|
|
||||||
|
#[Field(length: 12)]
|
||||||
|
public string $ipv4;
|
||||||
|
|
||||||
|
#[Field(length: 40)]
|
||||||
|
public string $ipv6;
|
||||||
|
|
||||||
|
#[Field]
|
||||||
|
public int $connectionTry = 0;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue