1.0.0 2022-03-07 12:54 UTC

This package is auto-updated.

Last update: 2024-09-13 06:13:54 UTC


README

这是一个小的Laravel中间件插件,用于阻止来自与俄罗斯和白俄罗斯相关的IP地址的请求。显示一条解释战争和这些制裁的消息。

安装

使用composer安装此包

composer require russia-sanctions/laravel

编辑 app/Http/Kernel.php 以将包设置为全局中间件(以便应用于所有请求)

protected $middleware = [
    // ... other middlewares

    // This should normally be included _after_ the TrustProxies
    // middleware, if you are using it, so that Laravel can correctly
    // identify the source IP address.
    \RussiaSanctions\Laravel\Middleware::class,
];