def ecp_auth_request(cls, entityid=None, relay_state='', sign=False):
 eelist = []
 my_url = cls.service_url(BINDING_PAOS)
 paos_request = paos.Request(must_understand='1', actor=ACTOR, response_consumer_url=my_url, service=SERVICE)
 eelist.append(element_to_extension_element(paos_request))
 relay_state = ecp.RelayState(actor=ACTOR, must_understand='1', text=relay_state)
 eelist.append(element_to_extension_element(relay_state))
 header = soapenv.Header()
 header.extension_elements = eelist
 logger.info(('entityid: %s, binding: %s' % (entityid, BINDING_SOAP)))
 location = cls._sso_location(entityid, binding=BINDING_SOAP)
 (req_id, authn_req) = cls.create_authn_request(location, binding=BINDING_PAOS, service_url_binding=BINDING_PAOS)
 body = soapenv.Body()
 body.extension_elements = [element_to_extension_element(authn_req)]
 soap_envelope = soapenv.Envelope(header=header, body=body)
 return (req_id, ('%s' % soap_envelope))

def ecp_auth_request ( cls , entityid = None , relay_state = '' , sign = False ) : eelist = [ ] my_url = cls . service_url ( BINDING_PAOS ) paos_request = paos . Request ( must_understand = '1' , actor = ACTOR , response_consumer_url = my_url , service = SERVICE ) eelist . append ( element_to_extension_element ( paos_request ) ) relay_state = ecp . RelayState ( actor = ACTOR , must_understand = '1' , text = relay_state ) eelist . append ( element_to_extension_element ( relay_state ) ) header = soapenv . Header ( ) header . extension_elements = eelist logger . info ( ( 'entityid: %s, binding: %s' % ( entityid , BINDING_SOAP ) ) ) location = cls . _sso_location ( entityid , binding = BINDING_SOAP ) ( req_id , authn_req ) = cls . create_authn_request ( location , binding = BINDING_PAOS , service_url_binding = BINDING_PAOS ) body = soapenv . Body ( ) body . extension_elements = [ element_to_extension_element ( authn_req ) ] soap_envelope = soapenv . Envelope ( header = header , body = body ) return ( req_id , ( '%s' % soap_envelope ) )
makes an authentication request .