@Bypass not functioning properly - Help needed! #37


  • New
  • Defect
Open
Assigned to _ForgeUser7448041
  • _ForgeUser9015852 created this issue Jun 15, 2012

    Greetings,

    I'm looking to report an issue I'm facing with PermissionsEx (PEX) & ScriptBlock (SB).

    I'm attempting to do a rather "complicated" function that'll assign a Heroes Class, Permission System & Kit to the player when they press the sign designated for that class. I'm wanting to do this for people who are sat on the default permission, so that people can't endlessly spam it, or switch classes.

    I've attempted to use the @bypass command, and it doesn't appear to be working. Here is what I am using:

    /sbinteract create [@bypass /heroes choose NAME][@bypass /pex user <player> group add NAME][@bypass /kit NAME]

    I've tried a simple version of this also:

    /sbinteract create @bypass /pex user <player> group add NAME

    Both of them return the error: You don't have permission to do this. Obviously the @bypass is meant to bypass all permissions requirements for those scripts. I'm not sure if this is an issue with PEX or SB, so I wanted to ask here, before I take it to PEX.

  • _ForgeUser9015852 added the tags New Defect Jun 15, 2012
  • _ForgeUser7448041 posted a comment Jun 16, 2012

    Sometimes some commands do not works with the "@bypass" commands. that's why there is an "@bypassPERM:" and "@bypassGROUP:" option

    it depends how the plugin's command you're trying to use is coded.

    Anyway I will try it , to be sure it's due to an incompatibility more than a coding issue.

  • _ForgeUser1569130 posted a comment Nov 13, 2013

    Same here, all of my @bypass are not working at all and it was functioning when 1.6.2. Not just me but my all 3 server owner friends also got same issue. We are all using pex. I am unsure if it is pex side but this problem is absolutely happening.Would you take time investigate this issue? Scriptblock is best solution for custom servers which rely on the @bypass function and a lot of server owners expecting to make it work.

  • _ForgeUser7448041 posted a comment Nov 13, 2013

    @umegonta: Go

    if it was working before... maybe something changed in Pex, Vault, or... bukkit... I will take a look to this problem.

    What version of minecraft , bukkit, vault, and pex are you using ?


    Edited Nov 13, 2013
  • _ForgeUser1569130 posted a comment Nov 14, 2013

    @Shereis: Go I personally investigated the problem. I am not specialist for neither java or bukkit API and I only tested like 10-15 minutes because I have no time these days.

    I found the fact the pex is overriding some permissions regardless if they are op or not. For example, using /timings command is not allowed for ops by default and pex was not preventing the command regardless if they got permission or not. More than that, "operators gets permission by default" never work with pex in my server setup. I had to give myself all of permissions manually to make ALL of my plugin's admin commands.

    I feel this issue is more like pex side but will you perform quick check of Scriptblock codes?

    My setup is;

    craftbukkit version 1.6.4 R2.0 (#2918) Vault version 1.2.2 pex version v1.20.4 ScriptBlock version v0.8.7

    This information is little offtopic but might help you. There is a plugin called "Command Sign" that works like Scriptblock. This plugin does almost exactly same what Scriptblock does. The plugin's cooldown function is working perfectly right now so some people prefer the plugin instead of Scriptblock (no criticism). But recently, the plugin is totally broken and players gets ALL OF permission when they interact the "signs" which can bypass all of permissions. The permission never be removed. Players could perform any command like /stop or /gamemode 1. That is how my friend is ended up using Scriptblock instead of "Command Sign" plugin. Don't you think this situation sounds like same issue that we are facing?

    Thanks for your hard work. My server is rely on your plugin.

  • _ForgeUser7448041 posted a comment Nov 14, 2013

    @umegonta: Go

    if the "command sign" plugin is the one I used to use before I created scriptblock, If I remember correctly... its bypass function works by giving all of the plugins permissions and remove them after use.

    Does the "@bypassPerm:" and "@bypassGroup:" option works ?

    if it does, then, I can confirm that, like you said the problem is pex side, as the @bypass option works in a very simple way. It juste promote the player to "Op" and remove it, if it was not OP before. it should also remove it if a java error occurs while performing the command. So if PEX do not works well with OP, then the @bypass will not work properly with PEX.

    Has you see there is only two possibilities of bypassing permissions, giving OP to a player or giving to him all permissions.

    So maybe you can fix your problem, by creating a "bypassgroup" in your permission file where you put all the permissions you want to be bypassed. and then replace all of unworking "@bypass" in your scripts by the "@bypassGROUP:bypassgroup".

    This shouldn't take long with a text editor like notepad++ and it's "replace all" function.

    Anyway what is the problem with the scriptblock cooldown option ?


    Edited Nov 14, 2013
  • _ForgeUser1569130 posted a comment Nov 14, 2013

    @Shereis: Go

    The @bypassgroup method worked like charm. Thanks. I also confirmed this issue can be avoided using @bypassPERM too.

    Thanks for providing good solution.

    #######

    Offtopic: The cooldown part

    For cooldown "issue", I cannot reproduce the problem so I have not reported it. The issue is the @cooldown option can be stopped working completely or the timer gonna spend like 1 minutes just to count one second by creating several scripts. I am sorry I couldn't be informational :(

    Also, all of cooldown timer will be shared if you make more than 1 timer in Scriptblock. My server owner friend wanted to make players rewarded by clicking beacon block but only once per 60 minutes. Plus, the beacon had to be all over the world so players can keep looking for beacons to be rewarded. Scriptblock shares cooldown timer with other scripts while "CommandSign" provides separated cooldown for each "signs". Scriptblock was not good taste for him. This is how my friend ended up using CommandSign instead. I don't know shared cooldown timer is intended in Scriptblock though.

    I don't think I can provide useful information about this since I have not tried to reproduce the issue so did not create ticket for it.

    I know this is not helpful information. Sorry for that.

  • _ForgeUser7448041 posted a comment Nov 15, 2013

    @umegonta: Go

    Pleased to see it's working well !

    Concerning the cooldown option... I think, I found the problem for unintended shared cooldowns !

    Maybe this will also fix the other cooldown issues...

  • _ForgeUser1569130 posted a comment Nov 15, 2013

    Hey I have updated information about this. I guess this is pex side but causing BIG issue for everybody who tried to use @bypassPERM option.

    The PermissionEX does NOT remove the permission you gave through @bypassPERM option after the scripted command is done.

    Be aware who tried to use this method. Your players can perform any command if you gave them the permission for the commands ANYTIME.

    @Shereis, You cannot solve this issue in scriptblock right?

  • _ForgeUser7448041 posted a comment Nov 16, 2013

    @umegonta: Go

    I think I've found where the "@bypassPERM" issue is coming from... and it's scriptblock side

    the plugin is running like that from more than one year and nobody reported it before... quite strange...


    Edited Nov 16, 2013

To post a comment, please login or register a new account.