Path: ...!3.eu.feeder.erje.net!feeder.erje.net!news2.arglkargh.de!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Lawrence D'Oliveiro Newsgroups: comp.arch Subject: Re: Byte Addressability And Beyond Date: Tue, 4 Jun 2024 01:45:58 -0000 (UTC) Organization: A noiseless patient Spider Lines: 15 Message-ID: References: <2024May29.090435@mips.complang.tuwien.ac.at> <1uJ5O.2$gn%7.1@fx12.iad> <2024May30.173537@mips.complang.tuwien.ac.at> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Tue, 04 Jun 2024 03:45:58 +0200 (CEST) Injection-Info: dont-email.me; posting-host="d7d916175bb629e2353c22c0a9deb72e"; logging-data="140054"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18V24FfmFXFW0WIcDbiYZ9X" User-Agent: Pan/0.158 (Avdiivka; ) Cancel-Lock: sha1:mWJM0JfSbRlX3dKI7a7zWQhVQw4= Bytes: 2091 On Thu, 30 May 2024 15:35:37 GMT, Anton Ertl wrote: > Actually what you check for is meta-characters like ; " '. They are all > ASCII, so as long as your code is 8-bit-clean, your SQL string sanitizer > needs to know nothing about UTF-8. According to the official spec, an SQL string literal is delimited by “"” characters, and an embedded double-quote is escaped by writing it twice: “""”. That’s it. Nothing else is special, so any other character/byte value in the string can be simply passed through as is. Of course, things like LIKE and REGEXP clauses are an entirely separate matter ...