summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/MessageAuthenticator.h
blob: 246961426e0401ad7182e4da6a93bc31ea7d1d9a (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
45
46
47
48
49
50
51
// **********************************************************************
//
// Copyright (c) 2002
// MutableRealms, Inc.
// Huntsville, AL, USA
//
// All Rights Reserved
//
// **********************************************************************

#ifndef ICE_MESSAGE_AUTHENTICATOR_H
#define ICE_MESSAGE_AUTHENTICATOR_H

#include <IceUtil/Shared.h>
#include <Ice/Stream.h>
#include <Ice/MessageAuthenticatorF.h>

namespace IceSecurity
{

namespace SecureUdp
{

using IceUtil::Shared;
using Ice::ByteSeq;

class MessageAuthenticator : public Shared
{

public:
    MessageAuthenticator();
    MessageAuthenticator(const ByteSeq&);
    virtual ~MessageAuthenticator();

    virtual ByteSeq computeMAC(const ByteSeq&) const;

    virtual bool authenticate(const ByteSeq&, const ByteSeq&);

    virtual const ByteSeq& getMACKey() const;

protected:
    ByteSeq _macKeyBytes;

};

}

}

#endif