~ubuntu-branches/ubuntu/utopic/pgadmin3/utopic-proposed

« back to all changes in this revision

Viewing changes to pgadmin/include/libssh2/mac.h

  • Committer: Package Import Robot
  • Author(s): Christoph Berg
  • Date: 2013-09-10 16:16:38 UTC
  • mfrom: (1.3.4)
  • Revision ID: package-import@ubuntu.com-20130910161638-wwup1q553ylww7dr
Tags: 1.18.0-1
* New upstream release.
* Don't install /usr/bin/png2c anymore.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef __LIBSSH2_MAC_H
 
2
#define __LIBSSH2_MAC_H
 
3
 
 
4
/* Copyright (C) 2009-2010 by Daniel Stenberg
 
5
 *
 
6
 * Redistribution and use in source and binary forms,
 
7
 * with or without modification, are permitted provided
 
8
 * that the following conditions are met:
 
9
 *
 
10
 *   Redistributions of source code must retain the above
 
11
 *   copyright notice, this list of conditions and the
 
12
 *   following disclaimer.
 
13
 *
 
14
 *   Redistributions in binary form must reproduce the above
 
15
 *   copyright notice, this list of conditions and the following
 
16
 *   disclaimer in the documentation and/or other materials
 
17
 *   provided with the distribution.
 
18
 *
 
19
 *   Neither the name of the copyright holder nor the names
 
20
 *   of any other contributors may be used to endorse or
 
21
 *   promote products derived from this software without
 
22
 *   specific prior written permission.
 
23
 *
 
24
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
 
25
 * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
 
26
 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
 
27
 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 
28
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
 
29
 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 
30
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
 
31
 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
 
32
 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 
33
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
 
34
 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 
35
 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
 
36
 * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
 
37
 * OF SUCH DAMAGE.
 
38
 *
 
39
 */
 
40
 
 
41
#include "libssh2_priv.h"
 
42
 
 
43
struct _LIBSSH2_MAC_METHOD
 
44
{
 
45
    const char *name;
 
46
 
 
47
    /* The length of a given MAC packet */
 
48
    int mac_len;
 
49
 
 
50
    /* integrity key length */
 
51
    int key_len;
 
52
 
 
53
    /* Message Authentication Code Hashing algo */
 
54
    int (*init) (LIBSSH2_SESSION * session, unsigned char *key, int *free_key,
 
55
                 void **abstract);
 
56
    int (*hash) (LIBSSH2_SESSION * session, unsigned char *buf,
 
57
                 uint32_t seqno, const unsigned char *packet,
 
58
                 uint32_t packet_len, const unsigned char *addtl,
 
59
                 uint32_t addtl_len, void **abstract);
 
60
    int (*dtor) (LIBSSH2_SESSION * session, void **abstract);
 
61
};
 
62
 
 
63
typedef struct _LIBSSH2_MAC_METHOD LIBSSH2_MAC_METHOD;
 
64
 
 
65
const LIBSSH2_MAC_METHOD **_libssh2_mac_methods(void);
 
66
 
 
67
#endif /* __LIBSSH2_MAC_H */