Develop and Download Open Source Software

Browse Subversion Repository

Annotation of /trunk/ttssh2/ttxssh/auth.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 9255 - (hide annotations) (download) (as text)
Wed May 19 14:11:26 2021 UTC (2 years, 10 months ago) by nmaya
File MIME type: text/x-chdr
File size: 3000 byte(s)
SSH2 暗号化方式 chacha20-poly1305@openssh.com をサポート

merge from branches/ssh_chacha20poly1305
r9209, r9210, r9211, r9212, r9217, r9229, r9248, r9249, r9250, r9251, r9252, r9253
1 maya 3227 /*
2 doda 6841 * Copyright (c) 1998-2001, Robert O'Callahan
3 nmaya 9048 * (C) 2004- TeraTerm Project
4 doda 6841 * All rights reserved.
5     *
6     * Redistribution and use in source and binary forms, with or without
7     * modification, are permitted provided that the following conditions
8     * are met:
9     *
10     * 1. Redistributions of source code must retain the above copyright
11     * notice, this list of conditions and the following disclaimer.
12     * 2. Redistributions in binary form must reproduce the above copyright
13     * notice, this list of conditions and the following disclaimer in the
14     * documentation and/or other materials provided with the distribution.
15     * 3. The name of the author may not be used to endorse or promote products
16     * derived from this software without specific prior written permission.
17     *
18     * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
19     * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
20     * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
21     * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY DIRECT, INDIRECT,
22     * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
23     * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24     * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25     * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26     * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27     * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28     */
29 maya 3227
30     /*
31     This code is copyright (C) 1998-1999 Robert O'Callahan.
32     See LICENSE.TXT for the license.
33     */
34    
35     #ifndef __AUTH_H
36     #define __AUTH_H
37    
38     #include <stdio.h>
39    
40     typedef struct {
41     SSHAuthMethod method;
42 doda 6801 char *password;
43     char *rhosts_client_user;
44 nmaya 9255 Key *key_pair;
45 maya 3227 } AUTHCred;
46    
47     typedef enum { GENERIC_AUTH_MODE, TIS_AUTH_MODE } AuthMode;
48    
49     typedef struct {
50 doda 6801 char *user;
51 maya 3227 AUTHCred cur_cred;
52     SSHAuthMethod failed_method;
53     int flags;
54     int supported_types;
55     HWND auth_dialog;
56    
57     AuthMode mode;
58 doda 6801 char *TIS_prompt;
59 doda 7477 int echo;
60 maya 3227 } AUTHState;
61    
62     void AUTH_init(PTInstVar pvar);
63 doda 6801 char *AUTH_get_user_name(PTInstVar pvar);
64 maya 3227 int AUTH_set_supported_auth_types(PTInstVar pvar, int types);
65     void AUTH_set_generic_mode(PTInstVar pvar);
66 doda 7477 void AUTH_set_TIS_mode(PTInstVar pvar, char *prompt, int len, int echo);
67 maya 3227 void AUTH_advance_to_next_cred(PTInstVar pvar);
68     void AUTH_do_cred_dialog(PTInstVar pvar);
69     void AUTH_do_default_cred_dialog(PTInstVar pvar);
70     void AUTH_destroy_cur_cred(PTInstVar pvar);
71 doda 6801 void AUTH_get_auth_info(PTInstVar pvar, char *dest, int len);
72 maya 3227 void AUTH_notify_disconnecting(PTInstVar pvar);
73     void AUTH_notify_end_error(PTInstVar pvar);
74 yutakapon 8093 void AUTH_notify_closing_on_exit(PTInstVar pvar);
75 maya 3227 void AUTH_end(PTInstVar pvar);
76 doda 6801 void destroy_malloced_string(char **str);
77 zmatsuo 7632 void init_password_control(PTInstVar pvar, HWND dlg, int item, BOOL *UseControlChar);
78 maya 3227
79     #define AUTH_get_cur_cred(pvar) (&(pvar)->auth_state.cur_cred)
80    
81     #endif

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26