PHPackages                             webazin/country-middleware - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. webazin/country-middleware

ActiveLibrary

webazin/country-middleware
==========================

country ban and country required captcha in route access

v1.0(4y ago)121MITPHP

Since Apr 18Pushed 4y agoCompare

[ Source](https://github.com/webazin/laravel-country-middleware)[ Packagist](https://packagist.org/packages/webazin/country-middleware)[ RSS](/packages/webazin-country-middleware/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (1)Versions (2)Used By (0)

Laravel package for countries access control
============================================

[](#laravel-package-for-countries-access-control)

Install
=======

[](#install)

---

1-`composer require webazin/country-middleware`

2-Insert in laravel &lt; 5
`config/app.php`

`\Webazin\CountryMiddleware\CountryMiddlewareServiceProvider::class`

3-`php artisan vendor:publish`

4-`Webazin\CountryMiddleware\CountryMiddlewareServiceProvider`

Use
===

[](#use)

---

In your route add

`->middleware('countryCheck')`

---

Ban country
===========

[](#ban-country)

---

`config/CountryMiddleware.php`

Add country iso\_code

For example

`countries_ban' => ['US']`

All iso code to below link
\[[https://en.wikipedia.org/wiki/List\_of\_ISO\_3166\_country\_codes](https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes)\]([https://en.wikipedia.org/wiki/List\_of\_ISO\_3166\_country\_codes](https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes)) ---

webazin.net

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1489d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/77ce3d4e5f45a422fb431d417329de94d8b99391fe2f131054f16fdb849a0f7a?d=identicon)[webazin](/maintainers/webazin)

---

Top Contributors

[![mahdi4187](https://avatars.githubusercontent.com/u/25785927?v=4)](https://github.com/mahdi4187 "mahdi4187 (23 commits)")

### Embed Badge

![Health badge](/badges/webazin-country-middleware/health.svg)

```
[![Health](https://phpackages.com/badges/webazin-country-middleware/health.svg)](https://phpackages.com/packages/webazin-country-middleware)
```

###  Alternatives

[jamesmills/laravel-timezone

Timezone storage and retrieval for Laravel

698764.1k12](/packages/jamesmills-laravel-timezone)[awssat/laravel-visits

Laravel Redis visits counter for Eloquent models

975163.6k2](/packages/awssat-laravel-visits)[acidjazz/humble

passwordless authentication and detailed sessioning for laravel

15136.5k](/packages/acidjazz-humble)[chowjiawei/laravel-help-plugin

Integrating useful auxiliary functions into laravel,Assistant tools based on laravel.

671.6k](/packages/chowjiawei-laravel-help-plugin)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
