Build the response BSON for SCRAM SHA256 AUTH request */
| 806 | |
| 807 | /* Build the response BSON for SCRAM SHA256 AUTH request */ |
| 808 | static pgbson * |
| 809 | BuildResponseMsgForAuthRequest(ScramAuthResult *authReqResult) |
| 810 | { |
| 811 | pgbson_writer resultWriter; |
| 812 | |
| 813 | PgbsonWriterInit(&resultWriter); |
| 814 | |
| 815 | PgbsonWriterAppendInt32(&resultWriter, AUTH_OK_KEY, AUTH_OK_KEY_LEN, |
| 816 | authReqResult->ok); |
| 817 | PgbsonWriterAppendUtf8(&resultWriter, AUTH_SERV_SIGN_KEY, |
| 818 | AUTH_SERV_SIGN_KEY_LEN, |
| 819 | authReqResult->serverSignature); |
| 820 | |
| 821 | return PgbsonWriterGetPgbson(&resultWriter); |
| 822 | } |
| 823 | |
| 824 | |
| 825 | /* Build the response BSON for Auth Message and Client Proof generator test |
no test coverage detected