Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1566944 - cpdb does not handle special characters in its parameters
Summary: cpdb does not handle special characters in its parameters
Keywords:
Status: NEW
Alias: None
Product: Candlepin
Classification: Community
Component: candlepin
Version: 2.1
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ---
: ---
Assignee: candlepin-bugs
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-13 08:12 UTC by Ales Dujicek
Modified: 2021-07-01 14:24 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description Ales Dujicek 2018-04-13 08:12:00 UTC
Description of problem:

for example ampersand in password causes cpdb to fail when cpdb calls liquibase

# cpdb --create --schema-only --dbhost=localhost --dbport=5432 --database='candlepin1db' --user='candlepin1' --password='c&ndlepin1pw'

########## ERROR ############
Error running command: liquibase --driver=org.postgresql.Driver --classpath=/usr/share/java/postgresql-jdbc.jar:/var/lib/tomcat/webapps/candlepin/WEB-INF/classes/ --changeLogFile=db/changelog/changelog-create.xml --url=jdbc:postgresql://localhost:5432/candlepin1db --username=candlepin1 --password=c&ndlepin1pw --logLevel=severe migrate -Dcommunity=False
Status code: 32512
Command output: sh: ndlepin1pw: command not found
Errors:
  Command not passed

the problem is 

Version-Release number of selected component (if applicable):
candlepin-2.1.14-1.el7.noarch

How reproducible:
always

Steps to Reproduce:
1. use special character in --database --user or --password parameter of cpdb


Note You need to log in before you can comment on or make changes to this bug.