Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Change shell to bash?

Discussion in 'cPanel Developers' started by FrankLaszlo, May 15, 2010.

  1. FrankLaszlo

    FrankLaszlo Active Member

    Joined:
    Dec 19, 2008
    Messages:
    35
    Likes Received:
    0
    Trophy Points:
    56
    So, I have the code to change a users shell with the xml-api in PHP. It works great if I want to switch it to jaillshell, or turn it off completely.. But it doesnt seem to accept "normal" or "bash" or "/bin/bash" as a valid shell.

    Anyone know the magic to make this work?

    My current query string is:

    Code:
            $query = "xml-api/modifyacct?user=$cpuser&shell=$newshell";
    
    As I said, I've tried various combinations for "newshell" but nothing seems to be accepted other than /usr/local/cpanel/bin/noshell or /usr/local/cpanel/bin/jailshell
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. akrzystek

    akrzystek Member

    Joined:
    Jul 8, 2005
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    151
    Afaik it's an open bug, see also:
    http://forums.cpanel.net/f185/cant-set-normal-shell-150505.html#post639089

    Thomas
     
  3. FrankLaszlo

    FrankLaszlo Active Member

    Joined:
    Dec 19, 2008
    Messages:
    35
    Likes Received:
    0
    Trophy Points:
    56
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice