{"id":19196962,"url":"https://github.com/jitesoft/simple-login","last_synced_at":"2025-10-08T22:43:14.791Z","repository":{"id":56999422,"uuid":"115003942","full_name":"jitesoft/simple-login","owner":"jitesoft","description":"PHP 7.1+ package for a simple login system.","archived":false,"fork":false,"pushed_at":"2018-03-22T10:09:05.000Z","size":84,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-08T22:43:14.043Z","etag":null,"topics":["authentication","login","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jitesoft.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-12-21T12:32:53.000Z","updated_at":"2018-03-22T10:09:06.000Z","dependencies_parsed_at":"2022-08-21T13:50:41.473Z","dependency_job_id":null,"html_url":"https://github.com/jitesoft/simple-login","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/jitesoft/simple-login","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jitesoft%2Fsimple-login","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jitesoft%2Fsimple-login/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jitesoft%2Fsimple-login/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jitesoft%2Fsimple-login/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jitesoft","download_url":"https://codeload.github.com/jitesoft/simple-login/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jitesoft%2Fsimple-login/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000779,"owners_count":26082851,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["authentication","login","php"],"created_at":"2024-11-09T12:15:01.138Z","updated_at":"2025-10-08T22:43:14.774Z","avatar_url":"https://github.com/jitesoft.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Simple Login\n\n[![Build Status](https://travis-ci.org/jitesoft/simple-login.svg?branch=master)](https://travis-ci.org/jitesoft/simple-login)\n\n[![codecov](https://codecov.io/gh/jitesoft/simple-login/branch/master/graph/badge.svg)](https://codecov.io/gh/jitesoft/simple-login)\n\nA simple login system which can be used as a standalone package or extended as a package in whatever framework you prefer.\n\nSimple login comes with a very simple dependency container. The container implements the PSR-11 container interface. Which makes it possible\nto switch to any other PSR-11 compatible container.  \nMost interfaces extends the PSR-3 `LoggerAwareInterface`, the default logger is a `NullLogger` which ignores all output, it \ncan easily be changed to another logged by binding the `PSR\\Log\\LoggerInterface` binding in the container or Config class.\n\n## Installation\n\n```\ncomposer require jitesoft/simple-login\n```\n\n## Usage\n\n### Out of the box\n\nA few of the interfaces in the package have to be implemented to be able to use the package.  \nThose include:\n\n* `Jitesoft\\SimpleLogin\\Auth\\AuthenticableInterface`\n* `Jitesoft\\SimpleLogin\\Auth\\AuthenticableRepositoryInterface`\n\nWhen implemented they have to be added to the package config to be possible to be used by the package.  \n\nThe `AuthenticableInterface` is supposed to be implemented by the User model of the project and the `AuthenticableRepositoryInterface` should\nhandle fetching of the user from whichever database or similar that is used.  \nIn the example directory, you can find a simple example of a implemented repository using `PDO`.\n\n## Changing the interfaces\n\nMost of the SimpleLogin classes can be changed to your own if wanted.\nIn most cases the interfaces just have to be bound to your own class and it should work right away.  \nFollowing is a list of interfaces that are used inside the system to make it work:\n\n* `CookieHandlerInterface` (Defaults to normal cookies).\n* `CryptoInterface` (Defaults to the blowfish algorithm).\n* `SessionStorageInterface` (Defaults to normal sessions).\n\nThe default implementations should be sufficient enough for most systems, but they can be easily changed by\nsetting your bindings when constructing the `Config` object that you pass into the `Jitesoft\\SimpleLogin\\Auth\\Authenticator` constructor.\n\nIf you wish to change the Container to another PSR-11 container, you can create a new Config class which inherits from the \n`Jitesoft\\SimpleLogin\\Config` class. Set the protected `$container` field to your specific Container implementation and it will\nbe used instead.\n\nBy default the following implementations are bound via the Config file:\n\n* `Jitesoft\\SimpleLogin\\`\n  * [`\\Cookies\\CookieHandlerInterface`](https://github.com/jitesoft/simple-login/blob/master/src/CookieHandler/CookieHandlerInterface.php) - [`\\Cookies\\CookieHandler`](https://github.com/jitesoft/simple-login/blob/master/src/CookieHandler/CookieHandler.php)\n  * [`\\Crypto\\CryptoInterface`](https://github.com/jitesoft/simple-login/blob/master/src/Crypto/CryptoInterface.php) - [`\\Crypto\\BlowfishCrypto`](https://github.com/jitesoft/simple-login/blob/master/src/Crypto/BlowfishCrypto.php)\n  * [`\\Sessions\\SessionStorageInterface`](https://github.com/jitesoft/simple-login/blob/master/src/SessionStorage/SessionStorageInterface.php) - [`\\Sessions\\SessionStorage`](https://github.com/jitesoft/simple-login/blob/master/src/SessionStorage/SessionStorage.php)\n* [`PSR\\Log\\LoggerInterface`](https://github.com/php-fig/log/blob/master/Psr/Log/LoggerInterface.php) - [`Jitesoft\\Log\\NullLogger`](https://github.com/jitesoft/php-loggers/blob/master/src/NullLogger.php)\n\n## Examples\n\nIn the [example](https://github.com/jitesoft/simple-login/tree/master/example) directory two examples can be found.  \n\nThe [LoginLogout](https://github.com/jitesoft/simple-login/tree/master/example/LogginLogout) example shows how to easily use the system to login and logout from a service. To test it, just serve\nthe index file via php (`php -S localhost:8000`) and navigate to `localhost:8000` in the browser. The faked user's password and username are both `admin`.\n\nThe [Repository](https://github.com/jitesoft/simple-login/tree/master/example/Repository) example shows how to easily implement your own repository to be used in the system, it uses a `PDO` object to \nhandle the database queries.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjitesoft%2Fsimple-login","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjitesoft%2Fsimple-login","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjitesoft%2Fsimple-login/lists"}