cancel
Showing results for 
Search instead for 
Did you mean: 

what is connector used for ? What are they ?

zengqingyi12
Champ in-the-making
Champ in-the-making
I saw the following code somewhere:
if (cachedNtlm)
{
Connector conn = connectorService.getConnector(this.endpoint, session);
ConnectorContext ctx = new ConnectorContext(null, getConnectionHeaders(conn));
remoteRes = conn.call("/touch", ctx, req, null);
}
else
{
Connector conn = connectorService.getConnector(this.endpoint, AuthenticationUtil.getUserId(req),
session);
ConnectorContext ctx = new ConnectorContext();
remoteRes = conn.call("/touch", ctx);
}

Can someone tell me what is this used for ? Are connector a web service ?
Where can I find more detailed information on this ?

How can Alfresco use connector to authenticate user ????

Thanks !!!
3 REPLIES 3

kevinr
Star Contributor
Star Contributor
I think that code is from the one of the Alfresco Share AuthenticationFilter classes.

Connectors and Authenticators are used under the covers in SpringSurf to perform and maintain the authentication credentials for user. So a user will be logged in over a connector to an endpoint (some remote server probably), and it is the responsibility of the connector to perform that work and then maintain the credentials (probably just an auth value in a cookie header or maybe a ticket value on a url) for future requests made by that user.

So for example in Alfresco Share, we make requests via the "alfresco" endpoint, which in turn uses the "alfresco-ticket" authenticator. Note that this is part of SpringSurf config out-of-the-box to make Alfresco connectivity easy.

To give you (and others who have asked similar questions) a better example, I will be writing a blog post shortly on creating a simple SpringSurf app that connects to an Alfresco repo to authenticate it's users.

Thanks,

Kev

zengqingyi12
Champ in-the-making
Champ in-the-making
I think that code is from the one of the Alfresco Share AuthenticationFilter classes.

Connectors and Authenticators are used under the covers in SpringSurf to perform and maintain the authentication credentials for user. So a user will be logged in over a connector to an endpoint (some remote server probably), and it is the responsibility of the connector to perform that work and then maintain the credentials (probably just an auth value in a cookie header or maybe a ticket value on a url) for future requests made by that user.

So for example in Alfresco Share, we make requests via the "alfresco" endpoint, which in turn uses the "alfresco-ticket" authenticator. Note that this is part of SpringSurf config out-of-the-box to make Alfresco connectivity easy.

To give you (and others who have asked similar questions) a better example, I will be writing a blog post shortly on creating a simple SpringSurf app that connects to an Alfresco repo to authenticate it's users.

Thanks,

Kev

Thanks very much, so can you also explain which when use the AuthenticationFilter for SSO, we need to call the touch point : alfresco/wcs/touch ?  What is this used for ?

kevinr
Star Contributor
Star Contributor
I think this post explains it fine: http://forums.alfresco.com/en/viewtopic.php?f=48&t=35400&p=102883#p102883
It is used to effectively start the authentication challenge procedure for the various SSO techniques, and to ensure that the user is still authenticated against the Alfresco server.