<s> from struct import unpack <EOL> from vertica_python . vertica . messages . message import BackendMessage <EOL> class Authentication ( BackendMessage ) : <EOL> OK = <NUM_LIT:0> <EOL> KERBEROS_V5 = <NUM_LIT:2> <EOL> CLEARTEXT_PASSWORD = <NUM_LIT:3> <EOL> CRYPT_PASSWORD = <NUM_LIT:4> <EOL> MD5_PASSWORD = <NUM_LIT:5> <EOL> SCM_CREDENTIAL = <NUM_LIT:6> <EOL> GSS = <NUM_LIT:7> <EOL> GSS_CONTINUE = <NUM_LIT:8> <EOL> SSPI = <NUM_LIT:9> <EOL> def __init__ ( self , data ) : <EOL> unpacked = unpack ( '<STR_LIT>' . format ( len ( data ) - <NUM_LIT:4> ) , data ) <EOL> self . code = unpacked [ <NUM_LIT:0> ] <EOL> other = unpacked [ <NUM_LIT:1> : : ] [ <NUM_LIT:0> ] <EOL> if self . code in [ self . CRYPT_PASSWORD , self . MD5_PASSWORD ] : <EOL> self . salt = other <EOL> if self . code in [ self . GSS_CONTINUE ] : <EOL> self . auth_data = other <EOL> Authentication . _message_id ( b'<STR_LIT:R>' ) </s>
