Configuration database password contains '&' anonimatron fails
Closed this issue · 1 comments
nasirhussain commented
Anonimatron version: 1.10.0
Operating system and version: Windows 10
Java runtime (java -version
): Java 8
Executed commands or actions: cannot connect to database
Expected outcome or behavior:
Actual outcome or behavior:
<configuration jdbcurl="jdbc:mysql://localhost:3306/testdb" userid="root" password="e8@JH$F&df">
Exception in thread "main" org.exolab.castor.xml.MarshalException: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 96; The reference to entity "df" must end with the ';' delimiter.{File: [not available]; line: 2; column: 96}
at org.exolab.castor.xml.Unmarshaller.convertSAXExceptionToMarshalException(Unmarshaller.java:832)
at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:703)
at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:589)
at com.rolfje.anonimatron.configuration.Configuration.readFromFile(Configuration.java:48)
at com.rolfje.anonimatron.Anonimatron.anonymize(Anonimatron.java:81)
realrolfje commented
The problem here seems to be that "&" is used in the string, and the xml parser expects valid xml, where the "&" should be escaped. Did you try to replace the "&" with "&" ? The example password in your case would be: "e8@JH$F&df"