Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-62255

Jenkins does not accept special characters in the password


    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • groovy-plugin
    • None

      We run our build with Jenkins using Groovy and we also use the 'bat' to run batch DB commands.

      Recently we're working on a project to randomize and rotate passwords.

      To this end we are generating a random ASCII string of N length and it uses chars between ASCII: 33 and 126, excluding: 34,39,47,58,92

      When we trigger a build using one of these strings as the password (obviously having created it in the DB for access,) we receive random errors, one error is "The system cannot find the file specified."

      This error referring to a file is quite strange as there is no file involved when we're trying to run this command, it is built on the fly:

      SET PGUSER=user_dqnvoryi& SET PGPASSWORD=7pIYV8#<0Xx& SET PGCLIENTENCODING=UTF8& psql -h pgwrapper.ebiqa.xhost.com -U user_dqnvoryi -d bipgdb -p 5432 -t -c "SELECT count as cnt FROM pg_database where datname = 'bisecus640458b';"


      See password highlighted in red above. If we change that password to a simpler string like: Abc123, then everything works as expected.


      Two characters we've found that the system doesn't work with are '@' and '&'.


      Two questions:

      Is there a way to escape special characters in this situation?

      If not, then which characters are not allowed so we can exclude them?



            kohsuke Kohsuke Kawaguchi
            ericblair Eric Blair
            0 Vote for this issue
            3 Start watching this issue