codename-B / bPermissions

a SuperPermissions manager for Bukkit
ci.xdevelopers.tk:8080/job/bPermissions/ws/target/bPermissions-1337-SNAPSHOT.jar
27 stars 39 forks source link

Case Sensetivity #13

Closed Sleaker closed 12 years ago

Sleaker commented 12 years ago

The way you're handling case-sensetivity is causing massive amounts of issues with people attempting to use your plugin.Confusion in what needs to be set, which plugins use uppercase-partially in their permission checks, and in plugins that need to add permissions transiently. I suggest going back to what Bukkit does, instead of breaking functionality from what bukkit already provides, like what certain other permission developers do...

Secondarily. Why would you possibly want case-sensitivity on them, when are you going to use 2 permissions that are identical but differently cased?

mlow commented 12 years ago

^ That one ^ Time to give up your terrible love for case sensitivity. :3

codename-B commented 12 years ago

Superperms automagically lowercases permissions - only if you're using override-player: true will that be an issue. bPermissions (playernames etc) can be lowercased via an option in config.yml

Sleaker commented 12 years ago

what about offline permissions that don't get handled through the override? also - I can't seem to find the override anymore, looks like that option was removed.

codename-B commented 12 years ago

@Sleaker

https://github.com/codename-B/bPermissions/blob/master/src/de/bananaco/permissions/Permissions.java#L546

lowercase-all: true/false

I don't know of any "offline permissions" that check against the bPermissions API however.

Sleaker commented 12 years ago

Vault does :-/ and I was referring to override-player. I don't see that option anymore. - Heroes also adds lowercased permissions, and people have a tendency to reference them using uppercase, this causes issues when doing the permission tests.

codename-B commented 12 years ago

Alright Sleaker, I'll get that added - but only for the hasPermission check - I'm afraid that the getAllPermissions should return (correctly cased) all permissions

Sleaker commented 12 years ago

why can't you just strip casing when you load the permissions from file? :o

You wouldn't need any of those casecheck statements during runtime either, I guess I just get confused on how stuff is getting set through.

codename-B commented 12 years ago

Because people might want cased prefix/suffixes etcetera.

Casing is a very tricky thing to deal with :/

Sleaker commented 12 years ago

and this is exactly why using permission nodes for chat info is not a good idea.

codename-B commented 12 years ago

Until metadata is implemented it's the only option that fits nicely with my system (even after it's implemented I may keep it)

codename-B commented 12 years ago

So I've whacked metadata into its own section.