Closed Bug 288709 Opened 20 years ago Closed 18 years ago

syncLDAP.pl cannot handle a regular name with " ' "

Categories

(Bugzilla :: Administration, task)

2.19.2
task
Not set
minor

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: eloft110, Unassigned)

Details

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (X11; U; IRIX64 IP35; en-US; rv:1.8b2) Gecko/R-A-C Firefox/1.0+
Build Identifier: 

The script syncLDAP.pl cannot handle a name like N'Diaye, Prud'homme anything
with a " ' " in the name. The "SendSQL" command should probably use the same
type of "SqlQuote" as in edituser.cgi. Since I'm not a perl programmer I can't
provide a patch.



Reproducible: Always
I've added the SQLQuote() calls, but I haven't got any LDAP server setup to
test with. Reporter, do you have a test install you could use to test this?
CC'ing original author of contributed script, in case Andreas wanted to
comment/check on the changes to the syncLDAP.pl script 
Comment on attachment 179396 [details]
Updated syncLDAP with added quoting

Don't use SqlQuote, use $dbh->quote or use placeholders.
Attachment #179396 - Flags: review-
(In reply to comment #1)
> Created an attachment (id=179396) [edit]
> Updated syncLDAP with added quoting
> 
> I've added the SQLQuote() calls, but I haven't got any LDAP server setup to
> test with. Reporter, do you have a test install you could use to test this?

I have tested it, I had to change SQLQuote to SqlQuote (note capital letters).
With this change, the script worked. Thank you.
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → WORKSFORME
It still needs to be actually fixed in CVS.
Status: RESOLVED → UNCONFIRMED
Resolution: WORKSFORME → ---
Severity: normal → minor
OS: Linux → All
Hardware: PC → All
Version: unspecified → 2.19.2
(In reply to comment #3)
> (From update of attachment 179396 [details] [edit])
> Don't use SqlQuote, use $dbh->quote or use placeholders.

Yes, I've started updating the script to use DBI.

Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
It looks like this script uses entirely DBI calls nowadays, since we eliminated all of the deprecated DB functions. So WORKSFORME.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago18 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: