6.0.0-beta1
▾
Tasks
New Task
Search
Photos
Wiki
▾
Tickets
New Ticket
Search
dev.horde.org
Toggle Alerts Log
Help
10/4/25
H
istory
A
ttachments
C
omment
W
atch
Download
Comment on [#9153] BYTEA DB escaping for postgres driver
*
Your Email Address
*
Spam protection
Enter the letters below:
.___..__ .__. __..__ _/ [__)| |(__ [__) ./__.| \|__\.__)[__)
Comment
> The problem is with replacing parameter placeholders in > Horde_Db_Adapter_Base::_replaceParameters(). This is the place where > we call quote() without a column parameter. > When using prepared statements we don't know the column types, and > parsing the prepared statement to query the database for column types > is out of question. > > I see two potential solutions for this: > 1) Analyze the column value and encode if necessary, e.g. if seeing a > control character. The problems is that such a character may or may > not appear in the values of such a column. > 2) Add a new wrapper class to Horde_Db that represent a value and can > be used for proper quoting, casting, escaping and encoding, e.g. > $value = new Horde_Db_Value($value, 'binary') or even $value = new > Horde_Db_Value_Binary($value).
Attachment
Watch this ticket
N
ew Ticket
M
y Tickets
S
earch
Q
uery Builder
R
eports
Saved Queries
Open Bugs
Bugs waiting for Feedback
Open Bugs in Releases
Open Enhancements
Enhancements waiting for Feedback
Bugs with Patches
Enhancements with Patches
Release Showstoppers
Stalled Tickets
New Tickets
Horde 5 Showstoppers