{"id":13795404,"url":"https://github.com/devarjhay/honeypot","last_synced_at":"2026-01-14T00:49:40.269Z","repository":{"id":56966286,"uuid":"101187337","full_name":"devarjhay/honeypot","owner":"devarjhay","description":"A simple spam protection for Laravel 5.4 and up.","archived":false,"fork":false,"pushed_at":"2020-09-22T07:57:07.000Z","size":10,"stargazers_count":5,"open_issues_count":1,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-05T19:31:02.512Z","etag":null,"topics":["honeypot","laravel","php","php-library","spam-prevention"],"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/devarjhay.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-23T14:08:12.000Z","updated_at":"2023-03-21T11:09:23.000Z","dependencies_parsed_at":"2022-08-21T11:20:16.822Z","dependency_job_id":null,"html_url":"https://github.com/devarjhay/honeypot","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/devarjhay/honeypot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devarjhay%2Fhoneypot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devarjhay%2Fhoneypot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devarjhay%2Fhoneypot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devarjhay%2Fhoneypot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devarjhay","download_url":"https://codeload.github.com/devarjhay/honeypot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devarjhay%2Fhoneypot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28407019,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T00:40:43.272Z","status":"ssl_error","status_checked_at":"2026-01-14T00:40:42.636Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["honeypot","laravel","php","php-library","spam-prevention"],"created_at":"2024-08-03T23:00:55.888Z","updated_at":"2026-01-14T00:49:40.246Z","avatar_url":"https://github.com/devarjhay.png","language":"PHP","funding_links":[],"categories":["\u003ca id=\"a53d22b9c5d09dc894413453f4755658\"\u003e\u003c/a\u003e未分类"],"sub_categories":[],"readme":"# Honeypot: Spam Prevention\nA simple spam prevention package for Laravel 5.4 and 5.5.\n\n# Installation:\n### Composer\nRun this command inside your terminal to add the package into your project.\n```\ncomposer require devarjhay/honeypot\n```\n\n# Configuration\n### Register the Honeypot Service Provider (Laravel 5.4 only)\nAdd the package to your application service providers in `config/app.php` file.\n```php\n'providers' =\u003e [\n\n  /*\n   * Laravel Framework Service Providers...\n   */\n   Illuminate\\Translation\\TranslationServiceProvider::class,\n   Illuminate\\Validation\\ValidationServiceProvider::class,\n   Illuminate\\View\\ViewServiceProvider::class,\n   ...\n   \n   /*\n    * Package Service Providers...\n    */\n   DevArjhay\\Honeypot\\Providers\\HoneypotServiceProvider::class,\n],\n```\n\n### Publish Config File and Translations\nOptimize the application\n```\nphp artisan optimize\n```\nPublish the package config file and translations to your application. Run this command inside your terminal.\n```\nphp artisan vendor:publish --provider=\"DevArjhay\\Honeypot\\Providers\\HoneypotServiceProvider\"\n```\nOr, you may want to publish the file individually.\n```\nphp artisan vendor:publish --provider=\"DevArjhay\\Honeypot\\Providers\\HoneypotServiceProvider\" --tag=\"config\"\nphp artisan vendor:publish --provider=\"DevArjhay\\Honeypot\\Providers\\HoneypotServiceProvider\" --tag=\"lang\"\n```\n\n# Usage\n### Using Facades\nAdd the honeypot hidden input into your form by inserting `Honeypot::make(...)` like this:\n```html\n\u003cform action=\"...\" method=\"...\"\u003e\n    {!! Honeypot::make('honeypot_name', 'honeypot_time') !!}\n\u003c/form\u003e\n```\n### Using Helpers\n```html\n\u003cform action=\"...\" method=\"...\"\u003e\n    {!! honeypot('honeypot_name', 'honeypot_time') !!}\n\u003c/form\u003e\n```\n### Using Blade Templates\n```html\n\u003cform action=\"...\" method=\"...\"\u003e\n    @honeypot('honeypot_name', 'honeypot_time')\n\u003c/form\u003e\n```\nThe `make` method will output the following HTML input. (The `honeypot_time` field will generate an encrypted tmestamps.\n```html\n\u003cdiv id=\"honeypot_name_wrap\" style=\"display: none;\"\u003e\n    \u003cinput type=\"text\" name=\"honeypot_name\" id=\"honeypot_name\" value=\"\" autocomplete=\"off\"\u003e\n    \u003cinput type=\"text\" name=\"honeypot_time\" id=\"honeypot_time\" value=\"encrypted timestamp\" autocomplete=\"off\"\u003e\n\u003c/div\u003e\n```\nAfter adding the honeypot fields. Add the validation rules for the honeypot and honey time fields.\n```php\n$this-\u003evalidate($request, [\n    ...\n    'honeypot_name' =\u003e 'honeypot',\n    'honeypot_time' =\u003e 'required|honeytime:5'\n]);\n```\nPlease note that you need to specify the number of seconds in honeytime. It should take for the user to fill up the form. If it takes less time than that the form is considered as a spam submission.\n\nI hope you enjoy getting a less spam when user submitting a form.\n\n# Credits\nThis project was based on https://github.com/msurguy/Honeypot – Maksim Surguy\u003cbr\u003e\nOriginal work on https://github.com/ianlandsman/Honeypot – Ian Landsman\n\n# License\nMIT License\n\nCopyright (c) 2017 Arjhay Delos Santos\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevarjhay%2Fhoneypot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevarjhay%2Fhoneypot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevarjhay%2Fhoneypot/lists"}