Class ScramAuthenticator


  • public class ScramAuthenticator
    extends java.lang.Object
    • Field Detail

      • LOGGER

        private static final java.util.logging.Logger LOGGER
      • user

        private final java.lang.String user
      • password

        private final java.lang.String password
      • pgStream

        private final PGStream pgStream
      • scramClient

        private com.ongres.scram.client.ScramClient scramClient
      • scramSession

        private com.ongres.scram.client.ScramSession scramSession
      • clientFinalProcessor

        private com.ongres.scram.client.ScramSession.ClientFinalProcessor clientFinalProcessor
    • Constructor Detail

      • ScramAuthenticator

        public ScramAuthenticator​(java.lang.String user,
                                  java.lang.String password,
                                  PGStream pgStream)
    • Method Detail

      • sendAuthenticationMessage

        private void sendAuthenticationMessage​(int bodyLength,
                                               ScramAuthenticator.BodySender bodySender)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • processServerMechanismsAndInit

        public void processServerMechanismsAndInit()
                                            throws java.io.IOException,
                                                   PSQLException
        Throws:
        java.io.IOException
        PSQLException
      • sendScramClientFirstMessage

        public void sendScramClientFirstMessage()
                                         throws java.io.IOException
        Throws:
        java.io.IOException
      • processServerFirstMessage

        public void processServerFirstMessage​(int length)
                                       throws java.io.IOException,
                                              PSQLException
        Throws:
        java.io.IOException
        PSQLException
      • verifyServerSignature

        public void verifyServerSignature​(int length)
                                   throws java.io.IOException,
                                          PSQLException
        Throws:
        java.io.IOException
        PSQLException