Adds composer and changes namespace
This commit is contained in:
@@ -1 +1,3 @@
|
||||
/nbproject/
|
||||
|
||||
/vendor/
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"name": "kavalanche/security",
|
||||
"description": "Security component for web applications",
|
||||
"type": "library",
|
||||
"authors": [
|
||||
{
|
||||
"name": "Wojtek",
|
||||
"email": "w.lk@wp.pl"
|
||||
}
|
||||
],
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Kavalanche\\Security\\": "src/"
|
||||
}
|
||||
},
|
||||
"require": {}
|
||||
}
|
||||
+3
-6
@@ -1,14 +1,11 @@
|
||||
<?php
|
||||
require __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
use App\Security\AuthenticationProvider;
|
||||
use App\Security\UserProviderInMemory;
|
||||
use Kavalanche\Security\AuthenticationProvider;
|
||||
use Kavalanche\Security\UserProviderInMemory;
|
||||
|
||||
session_start();
|
||||
|
||||
require __DIR__ . '/../src/Security/UserProviderInMemory.php';
|
||||
require __DIR__ . '/../src/Security/User.php';
|
||||
require __DIR__ . '/../src/Security/AuthenticationProvider.php';
|
||||
|
||||
if (isset($_GET['logout'])) {
|
||||
session_destroy();
|
||||
header('Location: ?');
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace App\Security;
|
||||
namespace Kavalanche\Security;
|
||||
|
||||
use Exception;
|
||||
|
||||
Binary file not shown.
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace App\Security;
|
||||
namespace Kavalanche\Security;
|
||||
|
||||
/**
|
||||
* @author Wojciech Burda <wojciech.burda@rp.pl>
|
||||
@@ -1,12 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace App\Security;
|
||||
namespace Kavalanche\Security;
|
||||
|
||||
use App\Security\User;
|
||||
use App\Security\UserProviderInterface;
|
||||
use Exception;
|
||||
|
||||
require __DIR__ . '/UserProviderInterface.php';
|
||||
use Kavalanche\Security\User;
|
||||
use Kavalanche\Security\UserProviderInterface;
|
||||
|
||||
/**
|
||||
* @author Wojciech Burda <wojciech.burda@rp.pl>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace App\Security;
|
||||
namespace Kavalanche\Security;
|
||||
|
||||
/**
|
||||
* @author Wojciech Burda <wojciech.burda@rp.pl>
|
||||
Reference in New Issue
Block a user