NetworkSecurity

插件

· 作者 Anyelo120

为你的网络提供安全保障。

0 本站下载 0 关注 更新于 1 年前

最新 2.0.2v · 1.21.9 · Bukkit / BungeeCord

一键开服(送7天)

Discord:

JAVA 11+

兼容:Spigot、Paper、Purpur、BungeeCord 和 Velocity

Velocity 需要 jsmysqlfix-velocity 插件

管理命令 (需要权限: securitynetwork.admin):

  • /ipadmin delete <ip> : 从缓存中移除一个 IP
  • /ipadmin stats : 显示被屏蔽和允许的 IP 数量
  • /ipadmin wipe : 清除整个数据库(需要确认)

权限

  • securitynetwork.bypass.vpn: 绕过 VPN 检查。
  • securitynetwork.bypass.country: 绕过国家检查。
  • securitynetwork.bypass.continent: 绕过大洲检查。
  • securitynetwork.bypass.all: 绕过所有检查。

Discord 权限

  • securitynetwork.discord.link: 允许使用 /vincular-discord 命令。
  • securitynetwork.discord.unlink: 允许使用 /desvincular-discord 命令。

存储方式

  • JSON: 将数据存储在本地 JSON 文件中(cache.json 和 player_country.json)。
  • MySQL/SQLite: 将数据存储在数据库中。

配置文件

剧透

bot-config.properties

bot.token=TU_TOKEN_AQUI
bot.channelId=ID_DEL_CANAL

Config.yml

# ===============================
# SecurityNetwork - 配置
# ===============================
# 此文件允许你通过过滤代理使用、国家或大洲来控制谁可以加入服务器。
# 你可以使用最多 3 个不同的 API 来检测 IP。
# -------------------------------
# 有用的 API 文档:
# - ProxyCheck.io: https://proxycheck.io/
# - IpInfo: https://ipinfo.io/
# - IPGeolocation: https://ipgeolocation.io/
#
# 国家代码 (ISO 3166-1 alpha-2): https://www.iban.com/country-codes
# 有效的大洲名称:Africa, Antarctica, Asia, Europe, North America, Oceania, South America
# ===============================
lang: es-es

api:
  # IP 检测服务的 API 密钥。
  # 如果你不想使用某个服务,请留空其 API 密钥。
# ===============================
# VPN 和代理 - 配置
# ===============================
  proxycheck: your-proxycheck-key # https://proxycheck.io/
  ipHub: your-proxycheck-key # https://iphub.info/
  ipQualityScore: your-proxycheck-key # https://www.ipqualityscore.com/

# ===============================
# 地理定位器 - 配置(非必需)
# ===============================
  ipinfo: your-ipinfo-token # https://ipinfo.io/
  ipgeolocation: your-ipgeolocation-key # https://ipgeolocation.io/

# 关于阻止尝试以下行为的用户的警报:
# - 接管账户
# - 使用 VPN 或代理
# - 不允许的国家
# - 不允许的大洲
webhook:
  discord: "https://discord.com/api/webhooks/..."

countries:
  # 定义国家过滤器的工作方式:
  # - "blacklist"(黑名单):仅阻止下面列出的国家。
  # - "whitelist"(白名单):仅允许下面列出的国家。
  mode: blacklist
  list:
    - US     # 美国
    - RU     # 俄罗斯

continents:
  # 定义大洲过滤器的工作方式:
  # - "blacklist"(黑名单):仅阻止下面列出的大洲。
  # - "whitelist"(白名单):仅允许下面列出的大洲。
  mode: whitelist
  list:
    - Europe
    - South America

storage:
  # 用于缓存和玩家-国家跟踪的存储类型。
  # Velocity/Bungee: "json", "mysql" <- 可用
  # Spigot/Paper/Purpur: "sqlite", "json" 或 "mysql" <- 可用
  type: json
  # 如果使用 MySQL,请取消注释并配置以下内容:
  # mysqlHost: localhost
  # mysqlPort: 3306
  # mysqlDatabase: network_security
  # mysqlUser: root
  # mysqlPassword: password123

EN-US.lang

ip.blocked.temp=§c⚠ 你的 IP 暂时被屏蔽。\n§7检查服务器 Discord 以确认你的身份。
ip.blocked=§c由于安全措施拒绝访问。\n§e认为这是错误? -> gg/gatitos

command.link.only-player=§c只有玩家才能使用此命令。
command.link.usage=§e用法: /link-discord <discord_name>
command.link.success=§7{0}
command.unlink.only-player=§c只有玩家才能使用此命令。
command.unlink.success=§7{0}

command.test.only-console=§c此命令只能从控制台运行。

command.admin.no-permission=§c你没有权限使用此命令。
command.admin.usage.delete=§c用法: /ipadmin delete <ip>
command.admin.usage.wipe=§c用法: /ipadmin wipe confirm
command.admin.ip-removed=§aIP {0} 已从缓存中移除。
command.admin.stats.title=§6--- IP 统计 ---
command.admin.stats.blocked=§c已屏蔽: §f{0}
command.admin.stats.allowed=§a已允许: §f{0}
command.admin.wipe.success=§4所有数据已从数据库中清除。
command.admin.wipe.failed=§c清除失败。请再试一次。
command.admin.unknown-subcommand=§c未知子命令。请使用: delete, stats, wipe
command.admin.help.header=§e用法:
command.admin.help.delete=§7/ipadmin delete <ip> - 从缓存中移除一个 IP
command.admin.help.stats=§7/ipadmin stats - 显示被屏蔽和允许的 IP 数量
command.admin.help.wipe=§7/ipadmin wipe - 警告!将清除整个数据库(需要确认)

command.test.usage=§e用法: /ipchecktest <ip>
command.test.success=§a命令对 IP {0} 执行成功
command.test.error=§c执行命令时出错: {0}

uuid.missing=§c无法获取玩家 UUID。\n§e认为这是错误? -> gg/gatitos
ip.missing=§c无法获取玩家 IP。\n§e认为这是错误? -> gg/gatitos

webhook.prefix.time=`[{0}]`
webhook.message.blocked=玩家 `{0}` 已被屏蔽。
webhook.reason.country-continent=由于受限制的国家或大洲而被屏蔽。\n国家: {0}\n大洲: {1}
webhook.reason.early-block=因国家/大洲限制而提前屏蔽。\n国家: {0}\n大洲: {1}
webhook.reason.proxy=因使用 VPN 或代理而阻止连接。\nIP: {0}\nUUID: {1}
webhook.reason.mismatch=可能的账户被盗:检测到国家不匹配。

discord.link.sent=✔ 请求已发送至 Discord。等待确认。
discord.link.not-found=❌ 未找到用户:{0}
discord.link.invalid-channel=❌ 无效的 Discord 频道。
discord.link.message=? <@{0}>,您有一个链接请求。点击接受以与 Minecraft UUID `{1}` 进行绑定
discord.link.expired=❌ 绑定请求已过期。

discord.unlink.requested=✔ 解绑请求已发送至 Discord。等待确认。
discord.unlink.not-linked=❌ 您的 Minecraft 账号尚未绑定。
discord.unlink.error=⚠ 检索绑定信息时出错。
discord.unlink.not-found=⚠ 未找到已绑定的用户。
discord.unlink.message=⚠ <@{0}>,您是否要**解绑**您的 Minecraft 账号?
discord.unlink.expired=⌛ 解绑请求已过期。

discord.confirmation.message=?️ <@{0}> 有人正尝试登录您的账号。是您本人吗?
discord.confirmation.expired=⌛ 确认请求已过期。
discord.confirmation.response=感谢您的回复。
discord.confirmation.error=❌ 无法删除身份验证消息。
discord.confirmation.no-link=❌ 未找到与此账号绑定的任何 Discord 用户。
discord.confirmation.channel-error=❌ 无法发送确认请求。请检查您的频道配置。
discord.confirmation.yes=是
discord.confirmation.no=否

discord.accept.expired=❌ 此请求已过期。
discord.accept.unauthorized=⚠ 您无权接受此请求。
discord.accept.already-linked=❌ 此 Minecraft 账号已绑定。
discord.accept.already-used=❌ 此 Discord 用户已绑定到其他账号。
discord.accept.success=✔ 绑定完成!
discord.accept.error=❌ 无法删除确认消息。

discord.unlink.confirm.success=✔ 您的账号已解绑。
discord.unlink.confirm.error=⚠ 解绑您的账号时出现问题。
discord.unlink.confirm.unauthorized=⚠ 只有已绑定的用户才能确认此操作。

使用方法 (SPIGOT/PAPER/PURPUR)

  • 运行您的服务器 (Spigot 或 Paper):
  • 启动服务器并享受 NetworkSecurity 带来的增强安全性。 插件将自动检查 IP 地址的代理、国家和大洲信息,以提升服务器安全性。

使用方法 (BUNGEECORD)

  • 安装插件: 将 NetworkSecurity.jar 文件放入您的 plugins 目录中。
  • 配置插件: 编辑 config.yml 文件以设置 ProxyCheck、IpInfo 和 IPGeolocation 的 API 密钥。 配置黑名单国家和大洲。 BungeeCord 仅支持 MySQL 和 JSON 存储。请在 config.yml 中选择您的存储类型。
  • 运行您的 BungeeCord 服务器: 启动 BungeeCord 服务器,NetworkSecurity 插件将根据 IP、国家、大洲和 VPN 状态开始监控并阻止用户。

使用方法 (VELOCITY)

  • 安装插件: 将 NetworkSecurity.jar 文件放入您的 plugins 目录中。
  • 配置插件: 编辑 config.yml 文件以配置 ProxyCheck、IpInfo 和 IPGeolocation 的 API 密钥。 设置您要阻止的国家和大洲,并管理绕过权限。
  • 依赖项: Velocity 需要 jsmysqlfix-velocity 依赖项才能启用 MySQL 支持,因为 Velocity 本身不带内置 SQL 驱动程序。 下载 jsmysqlfix-velocity 插件并与 NetworkSecurity 一起安装以支持 MySQL。
  • 运行您的 Velocity 服务器: 启动 Velocity 服务器,NetworkSecurity 将通过检查用户的国家、大洲和 VPN 状态来增强您的安全性,阻止不必要的访问。

你是这个资源的作者?登录后可认领此资源。

评论 0

0.0
暂无评分
5 星
0
4 星
0
3 星
0
2 星
0
1 星
0
我的评分

登录后参与评分

还没有评论,来抢沙发吧

评论配图

相似资源