Address SQL injection vulnerability in SQL ORM layer
authorMike Rylander <mrylander@gmail.com>
Fri, 5 Apr 2013 05:52:16 +0000 (01:52 -0400)
committerBill Erickson <berick@esilibrary.com>
Tue, 16 Apr 2013 17:24:52 +0000 (13:24 -0400)
commit29304fa2b5481c73c990ff0db8c9f22f4a9ccd28
treedc90acbb7f978b4144c2aa1e0c03c1ac9d08edff
parent432cab084e7dc92b10091e1a98925975bc7b360e
Address SQL injection vulnerability in SQL ORM layer

If the user-supplied value and the db column are both numbers
(jsonObject->type == JSON_NUMBER, get_primitive(field) == "number") then
don't quote. Otherwise, quote.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Open-ILS/src/c-apps/oils_sql.c