postgresql/src/interfaces/libpq/exports.txt

132 lines
3.8 KiB
Plaintext
Raw Normal View History

# $PostgreSQL: pgsql/src/interfaces/libpq/exports.txt,v 1.10 2006/05/23 22:14:27 momjian Exp $
# Functions to be exported by libpq DLLs
PQconnectdb 1
PQsetdbLogin 2
PQconndefaults 3
PQfinish 4
PQreset 5
PQrequestCancel 6
PQdb 7
PQuser 8
PQpass 9
PQhost 10
PQport 11
PQtty 12
PQoptions 13
PQstatus 14
PQerrorMessage 15
PQsocket 16
PQbackendPID 17
PQtrace 18
PQuntrace 19
PQsetNoticeProcessor 20
PQexec 21
PQnotifies 22
PQsendQuery 23
PQgetResult 24
PQisBusy 25
PQconsumeInput 26
PQgetline 27
PQputline 28
PQgetlineAsync 29
PQputnbytes 30
PQendcopy 31
PQfn 32
PQresultStatus 33
PQntuples 34
PQnfields 35
PQbinaryTuples 36
PQfname 37
PQfnumber 38
PQftype 39
PQfsize 40
PQfmod 41
PQcmdStatus 42
PQoidStatus 43
PQcmdTuples 44
PQgetvalue 45
PQgetlength 46
PQgetisnull 47
PQclear 48
PQmakeEmptyPGresult 49
PQprint 50
PQdisplayTuples 51
PQprintTuples 52
lo_open 53
lo_close 54
lo_read 55
lo_write 56
lo_lseek 57
lo_creat 58
lo_tell 59
lo_unlink 60
lo_import 61
lo_export 62
pgresStatus 63
PQmblen 64
PQresultErrorMessage 65
PQresStatus 66
termPQExpBuffer 67
appendPQExpBufferChar 68
initPQExpBuffer 69
resetPQExpBuffer 70
PQoidValue 71
PQclientEncoding 72
PQenv2encoding 73
appendBinaryPQExpBuffer 74
appendPQExpBufferStr 75
destroyPQExpBuffer 76
createPQExpBuffer 77
PQconninfoFree 78
PQconnectPoll 79
PQconnectStart 80
PQflush 81
PQisnonblocking 82
PQresetPoll 83
PQresetStart 84
PQsetClientEncoding 85
PQsetnonblocking 86
PQfreeNotify 87
PQescapeString 88
PQescapeBytea 89
printfPQExpBuffer 90
appendPQExpBuffer 91
pg_encoding_to_char 92
pg_utf_mblen 93
PQunescapeBytea 94
PQfreemem 95
PQtransactionStatus 96
PQparameterStatus 97
PQprotocolVersion 98
PQsetErrorVerbosity 99
PQsetNoticeReceiver 100
PQexecParams 101
PQsendQueryParams 102
PQputCopyData 103
PQputCopyEnd 104
PQgetCopyData 105
PQresultErrorField 106
PQftable 107
PQftablecol 108
PQfformat 109
PQexecPrepared 110
PQsendQueryPrepared 111
PQdsplen 112
PQserverVersion 113
PQgetssl 114
pg_char_to_encoding 115
pg_valid_server_encoding 116
pqsignal 117
PQprepare 118
PQsendPrepare 119
PQgetCancel 120
PQfreeCancel 121
PQcancel 122
lo_create 123
PQinitSSL 124
PQregisterThreadLock 125
Modify libpq's string-escaping routines to be aware of encoding considerations and standard_conforming_strings. The encoding changes are needed for proper escaping in multibyte encodings, as per the SQL-injection vulnerabilities noted in CVE-2006-2313 and CVE-2006-2314. Concurrent fixes are being applied to the server to ensure that it rejects queries that may have been corrupted by attempted SQL injection, but this merely guarantees that unpatched clients will fail rather than allow injection. An actual fix requires changing the client-side code. While at it we have also fixed these routines to understand about standard_conforming_strings, so that the upcoming changeover to SQL-spec string syntax can be somewhat transparent to client code. Since the existing API of PQescapeString and PQescapeBytea provides no way to inform them which settings are in use, these functions are now deprecated in favor of new functions PQescapeStringConn and PQescapeByteaConn. The new functions take the PGconn to which the string will be sent as an additional parameter, and look inside the connection structure to determine what to do. So as to provide some functionality for clients using the old functions, libpq stores the latest encoding and standard_conforming_strings values received from the backend in static variables, and the old functions consult these variables. This will work reliably in clients using only one Postgres connection at a time, or even multiple connections if they all use the same encoding and string syntax settings; which should cover many practical scenarios. Clients that use homebrew escaping methods, such as PHP's addslashes() function or even hardwired regexp substitution, will require extra effort to fix :-(. It is strongly recommended that such code be replaced by use of PQescapeStringConn/PQescapeByteaConn if at all feasible.
2006-05-21 22:19:23 +02:00
PQescapeStringConn 126
PQescapeByteaConn 127
PQencryptPassword 128
PQisthreadsafe 129