{"id":36370523,"url":"https://github.com/dederobert/duskphp-middleware","last_synced_at":"2026-01-11T14:00:38.837Z","repository":{"id":56986087,"uuid":"101487717","full_name":"dederobert/duskphp-middleware","owner":"dederobert","description":"A middleware's collection","archived":false,"fork":false,"pushed_at":"2017-08-27T14:17:04.000Z","size":24,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-11T10:19:45.092Z","etag":null,"topics":["csrf-prevention","csrf-protection","csrf-tokens","http-middleware","middleware","psr-15","psr-7"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dederobert.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-08-26T13:33:06.000Z","updated_at":"2019-08-23T18:48:16.000Z","dependencies_parsed_at":"2022-08-21T10:10:14.180Z","dependency_job_id":null,"html_url":"https://github.com/dederobert/duskphp-middleware","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/dederobert/duskphp-middleware","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dederobert%2Fduskphp-middleware","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dederobert%2Fduskphp-middleware/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dederobert%2Fduskphp-middleware/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dederobert%2Fduskphp-middleware/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dederobert","download_url":"https://codeload.github.com/dederobert/duskphp-middleware/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dederobert%2Fduskphp-middleware/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28306983,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-11T11:18:18.743Z","status":"ssl_error","status_checked_at":"2026-01-11T11:07:56.842Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["csrf-prevention","csrf-protection","csrf-tokens","http-middleware","middleware","psr-15","psr-7"],"created_at":"2026-01-11T14:00:20.429Z","updated_at":"2026-01-11T14:00:38.831Z","avatar_url":"https://github.com/dederobert.png","language":"PHP","readme":"# DuskPHP - Middleware\n[![Build Status](https://travis-ci.org/Hovensoft/duskphp-middleware.svg?branch=master)](https://travis-ci.org/Hovensoft/duskphp-middleware)\n[![Coverage Status](https://coveralls.io/repos/github/Hovensoft/duskphp-middleware/badge.svg?branch=master)](https://coveralls.io/github/Hovensoft/duskphp-middleware?branch=master)\n\n Provide middleware:\n - a CSRF authenticator which protect against CSRF attack with a token authentication \n\n ## How to use\n \n - ## CSRF Authenticator\n __How to use it ?__\n \n This middleware check every POST, PUT and DELETE request for a CSRF token.\n \n ```php\n $middleware = new CsrfMiddleware($_SESSION, 200);\n $dispatcher-\u003epipe($middleware);\n ```\n __Input__\n \n The middleware check if the string `\u003c:csrf_token_field:\u003e` is in response and replace it with \n the authenticator's token.\n \n ```html\n \u003cform action=\"\" method=\"post\"\u003e\n    ...\n    \u003c:csrf_token_field:\u003e\n\u003c/form\u003e\n```\n\n \n ## LICENSE\n \n DuskPHP - A simple PHP framework build with middleware pattern\n \n Copyright (C) 2017  HovenSoft\n \n This program is free software: you can redistribute it and/or modify\n it under the terms of the GNU General Public License as published by\n the Free Software Foundation, either version 3 of the License, or\n any later version\n \n This program is distributed in the hope that it will be useful,\n but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n GNU General Public License for more details.\n \n You should have received a copy of the GNU General Public License\n         along with this program.  If not, see [www.gnu.org/licenses](http://www.gnu.org/licenses).\n         \n \n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdederobert%2Fduskphp-middleware","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdederobert%2Fduskphp-middleware","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdederobert%2Fduskphp-middleware/lists"}