{"kind": "hook", "major": "18", "item": {"slug": "clientauthentication_hook", "name": "ClientAuthentication_hook", "name_zh": "ClientAuthentication_hook", "category": "Authentication and connections", "summary": "Hook for plugins to get control in ClientAuthentication()", "aliases": [], "versions": {"10": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_10_STABLE", "label": "10", "major": "10", "channel": "historical", "revision": "f4e8f137bfb08a664c8288824c1e36b5143ac875"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/f4e8f137bfb08a664c8288824c1e36b5143ac875/src/include/libpq/auth.h#L26", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "3a5f072463c74e5545c3e826363ce025c0e9beb72c3f1a8754fb8292f0d05342"}, {"url": "https://github.com/postgres/postgres/blob/f4e8f137bfb08a664c8288824c1e36b5143ac875/src/backend/libpq/auth.c#L236", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "15418faa6d6ee1b2a4ad1e50ebc9b34c2daf4799f7062df425e33dbf777ade61"}, {"url": "https://github.com/postgres/postgres/blob/f4e8f137bfb08a664c8288824c1e36b5143ac875/src/backend/libpq/auth.c#L597", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "15418faa6d6ee1b2a4ad1e50ebc9b34c2daf4799f7062df425e33dbf777ade61"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:597"]}, {"code": "\t\tcase uaTrust:\n\t\t\tstatus = STATUS_OK;\n\t\t\tbreak;\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:591\u2013605", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "11": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_11_STABLE", "label": "11", "major": "11", "channel": "historical", "revision": "170e416034ec0231d9e9238f2577eeb76ca8d181"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/170e416034ec0231d9e9238f2577eeb76ca8d181/src/include/libpq/auth.h#L26", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "f67fa69205f65d0be4db0088ab7c3a859ca35ccfa09a7f13e66725cf505f5ab7"}, {"url": "https://github.com/postgres/postgres/blob/170e416034ec0231d9e9238f2577eeb76ca8d181/src/backend/libpq/auth.c#L244", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "400ded30a0146825f89e86efc2a66a08f8f31a7391a4cc8ff61160e827885f1e"}, {"url": "https://github.com/postgres/postgres/blob/170e416034ec0231d9e9238f2577eeb76ca8d181/src/backend/libpq/auth.c#L605", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "400ded30a0146825f89e86efc2a66a08f8f31a7391a4cc8ff61160e827885f1e"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:605"]}, {"code": "\t\tcase uaTrust:\n\t\t\tstatus = STATUS_OK;\n\t\t\tbreak;\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:599\u2013613", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "12": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_12_STABLE", "label": "12", "major": "12", "channel": "historical", "revision": "3f302f0ed06f69c5ebd33d4df95895323a3cbef6"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/3f302f0ed06f69c5ebd33d4df95895323a3cbef6/src/include/libpq/auth.h#L26", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "e056d52ae2a186d7e06c36e234b359b78e84c68946eea3fb5ac9cc241bd6c5b9"}, {"url": "https://github.com/postgres/postgres/blob/3f302f0ed06f69c5ebd33d4df95895323a3cbef6/src/backend/libpq/auth.c#L240", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "2b9b1528350251095f1a992f21b279848cac098bc92ab0b46ce5c52e29e36ef0"}, {"url": "https://github.com/postgres/postgres/blob/3f302f0ed06f69c5ebd33d4df95895323a3cbef6/src/backend/libpq/auth.c#L613", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "2b9b1528350251095f1a992f21b279848cac098bc92ab0b46ce5c52e29e36ef0"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:613"]}, {"code": "#else\n\t\tAssert(false);\n#endif\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:607\u2013621", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "13": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_13_STABLE", "label": "13", "major": "13", "channel": "historical", "revision": "05f6c9ec2c475fae8fdd56ae40bd01afcf70d1f2"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/05f6c9ec2c475fae8fdd56ae40bd01afcf70d1f2/src/include/libpq/auth.h#L26", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "70ef80e7bd9cf3367cdd94796d021e4aea75e4ad8fa1d1c3b74fff0da311e203"}, {"url": "https://github.com/postgres/postgres/blob/05f6c9ec2c475fae8fdd56ae40bd01afcf70d1f2/src/backend/libpq/auth.c#L249", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "69b6071b483aaf91d9638ca58dafaa395063baf43b0d4a5421ab590bd3e3a04b"}, {"url": "https://github.com/postgres/postgres/blob/05f6c9ec2c475fae8fdd56ae40bd01afcf70d1f2/src/backend/libpq/auth.c#L618", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "69b6071b483aaf91d9638ca58dafaa395063baf43b0d4a5421ab590bd3e3a04b"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:618"]}, {"code": "#else\n\t\tAssert(false);\n#endif\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:612\u2013626", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "14": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_14_STABLE", "label": "14", "major": "14", "channel": "stable", "revision": "fba35c7c28a567839faba867db0808564c0a66db"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/fba35c7c28a567839faba867db0808564c0a66db/src/include/libpq/auth.h#L26", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "de30a014a41c0e60ef1bec9e8eea43e570176eb9c7de4e5417349442d26b391a"}, {"url": "https://github.com/postgres/postgres/blob/fba35c7c28a567839faba867db0808564c0a66db/src/backend/libpq/auth.c#L253", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "c8408d5f03a643baf14ca9f3e2d080ebd47325bd59804b0d5b89e242469d56c2"}, {"url": "https://github.com/postgres/postgres/blob/fba35c7c28a567839faba867db0808564c0a66db/src/backend/libpq/auth.c#L667", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "c8408d5f03a643baf14ca9f3e2d080ebd47325bd59804b0d5b89e242469d56c2"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:667"]}, {"code": "#else\n\t\tAssert(false);\n#endif\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:661\u2013675", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "15": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_15_STABLE", "label": "15", "major": "15", "channel": "stable", "revision": "0351991b8e7c7b64382e2f30ce581a8f276590a6"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/0351991b8e7c7b64382e2f30ce581a8f276590a6/src/include/libpq/auth.h#L28", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "c590dc7c1662362509f87d8458681023facbe5ab1859ef6b2b38c0516c1bf56a"}, {"url": "https://github.com/postgres/postgres/blob/0351991b8e7c7b64382e2f30ce581a8f276590a6/src/backend/libpq/auth.c#L244", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "fe7f3af2259e011b7033d1a45e948db3c8eebff5337c93ed9dcd638fb39b55c8"}, {"url": "https://github.com/postgres/postgres/blob/0351991b8e7c7b64382e2f30ce581a8f276590a6/src/backend/libpq/auth.c#L658", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "fe7f3af2259e011b7033d1a45e948db3c8eebff5337c93ed9dcd638fb39b55c8"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:658"]}, {"code": "#else\n\t\tAssert(false);\n#endif\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:652\u2013666", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "16": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_16_STABLE", "label": "16", "major": "16", "channel": "stable", "revision": "dcc37b7099a9f3cf2c75167d8dc92e75f96bc1fa"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/dcc37b7099a9f3cf2c75167d8dc92e75f96bc1fa/src/include/libpq/auth.h#L28", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "66c65b1a4254066bc368b56219742d0b3f21b8cad1c4cdf5bac5508414c94cd5"}, {"url": "https://github.com/postgres/postgres/blob/dcc37b7099a9f3cf2c75167d8dc92e75f96bc1fa/src/backend/libpq/auth.c#L240", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "6803da2f479c149bec539985f611a83df73716f2b79838f0c972959a2bf2ec65"}, {"url": "https://github.com/postgres/postgres/blob/dcc37b7099a9f3cf2c75167d8dc92e75f96bc1fa/src/backend/libpq/auth.c#L657", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "6803da2f479c149bec539985f611a83df73716f2b79838f0c972959a2bf2ec65"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:657"]}, {"code": "#else\n\t\tAssert(false);\n#endif\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:651\u2013665", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "17": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_17_STABLE", "label": "17", "major": "17", "channel": "stable", "revision": "163288afd32a448244c8df75b3c33181aadd7f20"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/163288afd32a448244c8df75b3c33181aadd7f20/src/include/libpq/auth.h#L28", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "a0066453dfde98129af96e8258339d958b4a400b967049ca7a9422adc7d8b8bf"}, {"url": "https://github.com/postgres/postgres/blob/163288afd32a448244c8df75b3c33181aadd7f20/src/backend/libpq/auth.c#L238", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "3257a7b822764268e1ac47c0002959c56d203d17b008538ecb179b48c6c64e0b"}, {"url": "https://github.com/postgres/postgres/blob/163288afd32a448244c8df75b3c33181aadd7f20/src/backend/libpq/auth.c#L671", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "3257a7b822764268e1ac47c0002959c56d203d17b008538ecb179b48c6c64e0b"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:671"]}, {"code": "\t\t\t\t\t   \"(%s:%d)\",\n\t\t\t\t\t   port->user_name, hba_authname(port->hba->auth_method),\n\t\t\t\t\t   port->hba->sourcefile, port->hba->linenumber));\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:665\u2013679", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "18": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_18_STABLE", "label": "18", "major": "18", "channel": "stable", "revision": "753057e340da8f22e57c9a409ea7a235fd6a46bd"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/include/libpq/auth.h#L45", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "976773a9612d289da53c43129ef0438a57904cdd19ffa2ca3d6d2b00104ec241"}, {"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/backend/libpq/auth.c#L223", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "94252cb1e2c49b0ddb15f6596d0abf8056c84493de07cc81439da4c5b07018f1"}, {"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/backend/libpq/auth.c#L664", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "94252cb1e2c49b0ddb15f6596d0abf8056c84493de07cc81439da4c5b07018f1"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:664"]}, {"code": "\t\t\t\t\t   \"(%s:%d)\",\n\t\t\t\t\t   port->user_name, hba_authname(port->hba->auth_method),\n\t\t\t\t\t   port->hba->sourcefile, port->hba->linenumber));\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:658\u2013672", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "19": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_19_BETA4", "label": "19 Beta 4", "major": "19", "channel": "preview", "revision": "b73d13c32c834a2c8e1c60cb92f79530376cedf1"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/b73d13c32c834a2c8e1c60cb92f79530376cedf1/src/include/libpq/auth.h#L45", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "8d296fc93077825992c59353c99cf4e3cb27407349c9e150a3ea90b2e36a2db2"}, {"url": "https://github.com/postgres/postgres/blob/b73d13c32c834a2c8e1c60cb92f79530376cedf1/src/backend/libpq/auth.c#L219", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "d3ab30f5024f21b3ba60959b760898f8d84ba0a90498c3cde8c24fbb8b6ea734"}, {"url": "https://github.com/postgres/postgres/blob/b73d13c32c834a2c8e1c60cb92f79530376cedf1/src/backend/libpq/auth.c#L668", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "d3ab30f5024f21b3ba60959b760898f8d84ba0a90498c3cde8c24fbb8b6ea734"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:668"]}, {"code": "\t\t\t\t\t   \"(%s:%d)\",\n\t\t\t\t\t   port->user_name, hba_authname(port->hba->auth_method),\n\t\t\t\t\t   port->hba->sourcefile, port->hba->linenumber));\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port,\n\t\t\t\t\tabandoned ? FATAL_CLIENT_ONLY : FATAL,\n\t\t\t\t\tstatus,\n\t\t\t\t\tlogdetail);", "title": "Core call context: src/backend/libpq/auth.c:662\u2013676", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "20": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "master", "label": "20 devel", "major": "20", "channel": "devel", "revision": "2c10c2ce4d7bcd57543a49ab402af02a39724e0a"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/2c10c2ce4d7bcd57543a49ab402af02a39724e0a/src/include/libpq/auth.h#L45", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "8d296fc93077825992c59353c99cf4e3cb27407349c9e150a3ea90b2e36a2db2"}, {"url": "https://github.com/postgres/postgres/blob/2c10c2ce4d7bcd57543a49ab402af02a39724e0a/src/backend/libpq/auth.c#L219", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "d3ab30f5024f21b3ba60959b760898f8d84ba0a90498c3cde8c24fbb8b6ea734"}, {"url": "https://github.com/postgres/postgres/blob/2c10c2ce4d7bcd57543a49ab402af02a39724e0a/src/backend/libpq/auth.c#L668", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "d3ab30f5024f21b3ba60959b760898f8d84ba0a90498c3cde8c24fbb8b6ea734"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:668"]}, {"code": "\t\t\t\t\t   \"(%s:%d)\",\n\t\t\t\t\t   port->user_name, hba_authname(port->hba->auth_method),\n\t\t\t\t\t   port->hba->sourcefile, port->hba->linenumber));\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port,\n\t\t\t\t\tabandoned ? FATAL_CLIENT_ONLY : FATAL,\n\t\t\t\t\tstatus,\n\t\t\t\t\tlogdetail);", "title": "Core call context: src/backend/libpq/auth.c:662\u2013676", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}}, "content_hash": "ffb7f90abd6354eec46a90a9341b34dc08a1bace366c386eef1a70dbfd87c0b7", "imported_at": "2026-09-27T09:57:58.826"}, "snapshot": {"facts": [{"label": "Interface type", "value": "ClientAuthentication_hook_type"}, {"label": "Header", "value": "src/include/libpq/auth.h"}, {"label": "Subsystem", "value": "Authentication and connections"}, {"label": "Initial value", "value": "NULL (no hook installed)"}], "related": [], "release": {"ref": "REL_18_STABLE", "label": "18", "major": "18", "channel": "stable", "revision": "753057e340da8f22e57c9a409ea7a235fd6a46bd"}, "sources": [{"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/include/libpq/auth.h#L45", "path": "src/include/libpq/auth.h", "label": "Interface declaration", "sha256": "976773a9612d289da53c43129ef0438a57904cdd19ffa2ca3d6d2b00104ec241"}, {"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/backend/libpq/auth.c#L223", "path": "src/backend/libpq/auth.c", "label": "Core definition", "sha256": "94252cb1e2c49b0ddb15f6596d0abf8056c84493de07cc81439da4c5b07018f1"}, {"url": "https://github.com/postgres/postgres/blob/753057e340da8f22e57c9a409ea7a235fd6a46bd/src/backend/libpq/auth.c#L664", "path": "src/backend/libpq/auth.c", "label": "Call sites", "sha256": "94252cb1e2c49b0ddb15f6596d0abf8056c84493de07cc81439da4c5b07018f1"}], "sections": [{"title": "Core source comments", "paragraphs": ["This hook allows plugins to get control following client authentication, but before the user has been informed about the results. It could be used to record login events, insert a delay after failed authentication, etc."]}, {"title": "Call sites", "paragraphs": ["src/backend/libpq/auth.c:664"]}, {"code": "\t\t\t\t\t   \"(%s:%d)\",\n\t\t\t\t\t   port->user_name, hba_authname(port->hba->auth_method),\n\t\t\t\t\t   port->hba->sourcefile, port->hba->linenumber));\n\t}\n\n\tif (ClientAuthentication_hook)\n\t\t(*ClientAuthentication_hook) (port, status);\n\n\tif (status == STATUS_OK)\n\t\tsendAuthRequest(port, AUTH_REQ_OK, NULL, 0);\n\telse\n\t\tauth_failed(port, status, logdetail);\n}\n\n", "title": "Core call context: src/backend/libpq/auth.c:658\u2013672", "paragraphs": []}], "signature": "typedef void (*ClientAuthentication_hook_type) (Port *, int);\nextern PGDLLIMPORT ClientAuthentication_hook_type ClientAuthentication_hook;", "description": ["Hook for plugins to get control in ClientAuthentication()"]}, "comparison": {"left": "17", "right": "18", "status": "unchanged", "diff": ""}}