aplus-framework / app

Aplus Framework App Project
https://aplus-framework.com/packages/app
MIT License
576 stars 22 forks source link

Authentication System #4

Open tahaghafuri opened 1 year ago

tahaghafuri commented 1 year ago

Hi,Please Create Authentication Library For A+ Framework!

tahaghafuri commented 1 year ago

????

natanfelles commented 1 year ago

Hello @tahaghafuri !

We plan to create an Auth Library soon, but we don't have the necessary use cases yet.

We plan to use token based, session and ACL.

It is currently possible to authenticate using methods of the Framework\HTTP\Request class.

In a controller you can do this:

$auth = $this->request->getBasicAuth(); // array with username and password keys

or

$auth = $this->request->getBearerAuth(); // array with token key

So just check if the authentication data are in, for example, the database.