Skip to content

ban/shadowban/whitelist for IPs#172

Closed
JunkyDeveloper wants to merge 68 commits into
Steel-Foundation:masterfrom
JunkyDeveloper:ban-allow-ips
Closed

ban/shadowban/whitelist for IPs#172
JunkyDeveloper wants to merge 68 commits into
Steel-Foundation:masterfrom
JunkyDeveloper:ban-allow-ips

Conversation

@JunkyDeveloper

@JunkyDeveloper JunkyDeveloper commented May 1, 2026

Copy link
Copy Markdown
Contributor

Added the commands:

  • /whitelist-ip list
  • /shadowban-ip add/remove/list
  • /ban-ip <ip|player> <reason|expire>
  • /pardon-ip
  • /kick

Thanks @HT06 for this work and help here!

it saves in ip-bans.toml.
More information and the documentation about everything can be found in this PR.
Also a converter from minecraft format to steel format is added.
If steel doesn't find at boot the ip-bans.toml it looks if banned-ip.json can be found and load the data from that.
This can be also triggert via CLI with: ./steel convert banned-ip which loads the data and saves it to disk. The server will not be started

JunkyDeveloper and others added 30 commits April 22, 2026 20:19
Basic implementation of kick command
… also do a refresh command, to load things from disk or save it to disk
start implementing duration of the ban
…the whitelist is already applied on socket level
@JunkyDeveloper JunkyDeveloper requested a review from coco875 June 7, 2026 23:18

@coco875 coco875 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just small comment


/// Path to Steel's bans file (`config/ip-bans.toml`).
pub const STEEL_IP_BANS_PATH: &str = "config/banned-ips.toml";
const MINECRAFT_BANNED_IP_PATH: &str = "config/banned-ips.json";

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't know if 4lve prefer no file and if migration it should have, it will be with a tool and not steel but not sure, personally I am fine with that

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will let this comment open for him

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

found out, there is a command names cli params like ./steel convert banned-ip which converts the minecraft to steel format XD thanks for codex to point that out :D

Comment thread steel-core/src/network/ip_access_policy.rs Outdated
Comment thread steel-core/src/network/ip_access_policy.rs Outdated
@JunkyDeveloper JunkyDeveloper marked this pull request as draft June 15, 2026 16:54
@github-actions

Copy link
Copy Markdown

This pull request has conflicts with the base branch "master". Please resolve those so we can test out your changes.

# Conflicts:
#	steel-login/src/tcp_client.rs
#	steel/src/lib.rs
#	steel/src/main.rs
@github-actions

Copy link
Copy Markdown

Conflicts have been resolved! 🎉

@JunkyDeveloper JunkyDeveloper marked this pull request as ready for review June 17, 2026 13:08
@github-actions

Copy link
Copy Markdown

This pull request has conflicts with the base branch "master". Please resolve those so we can test out your changes.

# Conflicts:
#	steel/src/config.rs
#	steel/src/main.rs
@github-actions

Copy link
Copy Markdown

Conflicts have been resolved! 🎉

@coco875 coco875 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions

Copy link
Copy Markdown

This pull request has conflicts with the base branch "master". Please resolve those so we can test out your changes.

@github-actions

Copy link
Copy Markdown

Conflicts have been resolved! 🎉

@4lve

4lve commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator

Thanks for the PR. I like the idea with the steel CLI. But after reviewing it I think the PR is trying to solve too many things at once and has some foundation issues we should not merge as-is

I’m going to close this PR for now instead of asking for a large rewrite. The work is still useful as a reference!

@4lve 4lve closed this Jun 23, 2026
@JunkyDeveloper

Copy link
Copy Markdown
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants