~ubuntu-branches/ubuntu/quantal/freerdp/quantal

« back to all changes in this revision

Viewing changes to libfreerdp/credssp.h

  • Committer: Bazaar Package Importer
  • Author(s): Otavio Salvador
  • Date: 2010-06-23 21:39:09 UTC
  • Revision ID: james.westby@ubuntu.com-20100623213909-bb9pvvv03913tdv6
Tags: upstream-0.7.1
ImportĀ upstreamĀ versionĀ 0.7.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- c-basic-offset: 8 -*-
 
2
   FreeRDP: A Remote Desktop Protocol client.
 
3
   Credential Security Support Provider (CredSSP)
 
4
 
 
5
   Copyright (C) Marc-Andre Moreau <marcandre.moreau@gmail.com> 2010
 
6
 
 
7
   This program is free software; you can redistribute it and/or modify
 
8
   it under the terms of the GNU General Public License as published by
 
9
   the Free Software Foundation; either version 2 of the License, or
 
10
   (at your option) any later version.
 
11
 
 
12
   This program is distributed in the hope that it will be useful,
 
13
   but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
15
   GNU General Public License for more details.
 
16
 
 
17
   You should have received a copy of the GNU General Public License
 
18
   along with this program; if not, write to the Free Software
 
19
   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
20
*/
 
21
 
 
22
#ifndef __CREDSSP_H
 
23
#define __CREDSSP_H
 
24
 
 
25
#include "secure.h"
 
26
 
 
27
struct _AV_PAIR
 
28
{
 
29
        uint16 length;
 
30
        uint8* value;
 
31
};
 
32
typedef struct _AV_PAIR AV_PAIR;
 
33
 
 
34
struct _AV_PAIRS
 
35
{
 
36
        AV_PAIR NbComputerName;
 
37
        AV_PAIR NbDomainName;
 
38
        AV_PAIR DnsComputerName;
 
39
        AV_PAIR DnsDomainName;
 
40
        AV_PAIR DnsTreeName;
 
41
        AV_PAIR Timestamp;
 
42
        AV_PAIR Restrictions;
 
43
        AV_PAIR TargetName;
 
44
        AV_PAIR ChannelBindings;
 
45
        uint32 Flags;
 
46
};
 
47
typedef struct _AV_PAIRS AV_PAIRS;
 
48
 
 
49
enum _AV_ID
 
50
{
 
51
        MsvAvEOL,
 
52
        MsvAvNbComputerName,
 
53
        MsvAvNbDomainName,
 
54
        MsvAvDnsComputerName,
 
55
        MsvAvDnsDomainName,
 
56
        MsvAvDnsTreeName,
 
57
        MsvAvFlags,
 
58
        MsvAvTimestamp,
 
59
        MsvAvRestrictions,
 
60
        MsvAvTargetName,
 
61
        MsvChannelBindings
 
62
};
 
63
typedef enum _AV_ID AV_ID;
 
64
 
 
65
struct rdp_nla
 
66
{
 
67
        struct rdp_sec * sec;
 
68
        AV_PAIRS* target_info;
 
69
        uint8* target_name;
 
70
        uint32 negotiate_flags;
 
71
        uint8 server_challenge[8];
 
72
};
 
73
typedef struct rdp_nla rdpNla;
 
74
 
 
75
void
 
76
credssp_send(rdpSec * sec, STREAM s);
 
77
void
 
78
credssp_recv(rdpSec * sec);
 
79
 
 
80
void
 
81
ntlm_send_negotiate_message(rdpSec * sec);
 
82
void
 
83
ntlm_recv_challenge_message(rdpSec * sec, STREAM s);
 
84
void
 
85
ntlm_send_authenticate_message(rdpSec * sec);
 
86
void
 
87
ntlm_recv(rdpSec * sec, STREAM s);
 
88
 
 
89
rdpNla *
 
90
nla_new(rdpSec * sec);
 
91
void
 
92
nla_free(rdpNla * nla);
 
93
 
 
94
#endif // __CREDSSP_H
 
95