blob: 98d1b5165ff377035abe2996c8bcbf26afb77982 [file] [log] [blame]
Weiweie5640c62015-07-31 01:43:01 -07001# -*- Mode:python; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
2#
3# Copyright (C) 2014 Regents of the University of California.
4# Author: Weiwei Liu <summerwing10@gmail.com>
5# This program is free software: you can redistribute it and/or modify
6# it under the terms of the GNU Lesser General Public License as published by
7# the Free Software Foundation, either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU General Public License for more details.
14#
15# You should have received a copy of the GNU General Public License
16# along with this program. If not, see <http://www.gnu.org/licenses/>.
17# A copy of the GNU General Public License is in the file COPYING.
18
19class HMACKey(object):
20 """
21 HMACKey implements the HMAC symmetric key
22 """
23 def __init__(self, sequence, counter, key, name = None):
24 self._name = name
25 self._sequence = sequence
26 self._counter = counter
27 self._key = key
28
29 def getName(self):
30 return self._name
31
32 def getSequence(self):
33 return self._sequence
34
35 def getCounter(self):
36 return self._counter
37
38 def getKey(self):
39 return self._key
40