postgresql/src/interfaces/libpq/exports.txt

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

194 lines
5.6 KiB
Plaintext
Raw Normal View History

2010-09-20 22:08:53 +02:00
# src/interfaces/libpq/exports.txt
# 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
enlargePQExpBuffer 130
PQnparams 131
PQparamtype 132
PQdescribePrepared 133
PQdescribePortal 134
PQsendDescribePrepared 135
PQsendDescribePortal 136
lo_truncate 137
PQconnectionUsedPassword 138
Fix the inadvertent libpq ABI breakage discovered by Martin Pitt: the renumbering of encoding IDs done between 8.2 and 8.3 turns out to break 8.2 initdb and psql if they are run with an 8.3beta1 libpq.so. For the moment we can rearrange the order of enum pg_enc to keep the same number for everything except PG_JOHAB, which isn't a problem since there are no direct references to it in the 8.2 programs anyway. (This does force initdb unfortunately.) Going forward, we want to fix things so that encoding IDs can be changed without an ABI break, and this commit includes the changes needed to allow libpq's encoding IDs to be treated as fully independent of the backend's. The main issue is that libpq clients should not include pg_wchar.h or otherwise assume they know the specific values of libpq's encoding IDs, since they might encounter version skew between pg_wchar.h and the libpq.so they are using. To fix, have libpq officially export functions needed for encoding name<=>ID conversion and validity checking; it was doing this anyway unofficially. It's still the case that we can't renumber backend encoding IDs until the next bump in libpq's major version number, since doing so will break the 8.2-era client programs. However the code is now prepared to avoid this type of problem in future. Note that initdb is no longer a libpq client: we just pull in the two source files we need directly. The patch also fixes a few places that were being sloppy about checking for an unrecognized encoding name.
2007-10-13 22:18:42 +02:00
pg_valid_server_encoding_id 139
PQconnectionNeedsPassword 140
lo_import_with_oid 141
PQcopyResult 142
PQsetResultAttrs 143
PQsetvalue 144
PQresultAlloc 145
PQregisterEventProc 146
PQinstanceData 147
PQsetInstanceData 148
PQresultInstanceData 149
PQresultSetInstanceData 150
PQfireResultCreateEvents 151
PQconninfoParse 152
PQinitOpenSSL 153
PQescapeLiteral 154
PQescapeIdentifier 155
PQconnectdbParams 156
PQconnectStartParams 157
PQping 158
PQpingParams 159
PQlibVersion 160
PQsetSingleRowMode 161
lo_lseek64 162
lo_tell64 163
lo_truncate64 164
PQconninfo 165
PQsslInUse 166
PQsslStruct 167
PQsslAttributeNames 168
PQsslAttribute 169
PQsetErrorContextVisibility 170
PQresultVerboseErrorMessage 171
PQencryptPasswordConn 172
PQresultMemorySize 173
PQhostaddr 174
GSSAPI encryption support On both the frontend and backend, prepare for GSSAPI encryption support by moving common code for error handling into a separate file. Fix a TODO for handling multiple status messages in the process. Eliminate the OIDs, which have not been needed for some time. Add frontend and backend encryption support functions. Keep the context initiation for authentication-only separate on both the frontend and backend in order to avoid concerns about changing the requested flags to include encryption support. In postmaster, pull GSSAPI authorization checking into a shared function. Also share the initiator name between the encryption and non-encryption codepaths. For HBA, add "hostgssenc" and "hostnogssenc" entries that behave similarly to their SSL counterparts. "hostgssenc" requires either "gss", "trust", or "reject" for its authentication. Similarly, add a "gssencmode" parameter to libpq. Supported values are "disable", "require", and "prefer". Notably, negotiation will only be attempted if credentials can be acquired. Move credential acquisition into its own function to support this behavior. Add a simple pg_stat_gssapi view similar to pg_stat_ssl, for monitoring if GSSAPI authentication was used, what principal was used, and if encryption is being used on the connection. Finally, add documentation for everything new, and update existing documentation on connection security. Thanks to Michael Paquier for the Windows fixes. Author: Robbie Harwood, with changes to the read/write functions by me. Reviewed in various forms and at different times by: Michael Paquier, Andres Freund, David Steele. Discussion: https://www.postgresql.org/message-id/flat/jlg1tgq1ktm.fsf@thriss.redhat.com
2019-04-03 21:02:33 +02:00
PQgssEncInUse 175
PQgetgssctx 176
PQsetSSLKeyPassHook_OpenSSL 177
PQgetSSLKeyPassHook_OpenSSL 178
PQdefaultSSLKeyPassHook_OpenSSL 179
PQenterPipelineMode 180
PQexitPipelineMode 181
PQpipelineSync 182
PQpipelineStatus 183
PQsetTraceFlags 184
PQmblenBounded 185
PQsendFlushRequest 186
PQconnectionUsedGSSAPI 187
PQclosePrepared 188
PQclosePortal 189
PQsendClosePrepared 190
PQsendClosePortal 191