aboutsummaryrefslogtreecommitdiffstats
path: root/test/net/java/sip/communicator/slick/protocol/generic/AuthHandler.java
blob: ce3551dd9ad7c886ea204d4fc3ddf993147af2eb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
 * Jitsi, the OpenSource Java VoIP and Instant Messaging client.
 *
 * Distributable under LGPL license.
 * See terms of license at gnu.org.
 */
package net.java.sip.communicator.slick.protocol.generic;

import net.java.sip.communicator.service.protocol.*;
import net.java.sip.communicator.util.*;

/**
 * Implementation for the authorization handler.
 */
public class AuthHandler
implements AuthorizationHandler
{

    private static final Logger logger =
        Logger.getLogger(AuthHandler.class);

    public AuthorizationResponse processAuthorisationRequest(
        AuthorizationRequest req, Contact sourceContact)
    {
        logger.trace("processAuthorisationRequest " + req + " " +
            sourceContact);

        return new AuthorizationResponse(AuthorizationResponse.ACCEPT, "");
    }

    public AuthorizationRequest createAuthorizationRequest(Contact contact)
    {
        logger.trace("createAuthorizationRequest " + contact);
        return new AuthorizationRequest();
    }

    public void processAuthorizationResponse(
        AuthorizationResponse response, Contact sourceContact)
    {
        logger.debug("auth response from: " +
            sourceContact.getAddress() + " " +
            response.getResponseCode().getCode());
    }
}