DefaultAuthMethods Property

Specifies the supported authentication methods.


ANSI (Cross Platform)
char* GetDefaultAuthMethods();
int SetDefaultAuthMethods(const char* lpszDefaultAuthMethods); Unicode (Windows) LPWSTR GetDefaultAuthMethods();
INT SetDefaultAuthMethods(LPCWSTR lpszDefaultAuthMethods);
@property (nonatomic,readwrite,assign,getter=defaultAuthMethods,setter=setDefaultAuthMethods:) NSString* defaultAuthMethods;
- (NSString*)defaultAuthMethods;
- (void)setDefaultAuthMethods:(NSString*)newDefaultAuthMethods;

IPWORKSSFTP_EXTERNAL void* IPWORKSSFTP_CALL IPWorksSFTP_SFTPServer_Get(void *lpObj, int propid, int arridx, int *lpcbVal, int64 *lpllVal);
IPWORKSSFTP_EXTERNAL int IPWORKSSFTP_CALL IPWorksSFTP_SFTPServer_Set(void *lpObj, int propid, int arridx, const void *val, int cbVal);

Default Value



This property specifies the supported authentication methods. The client will choose one of the supported mechanisms when authenticating to the class.

This must be a comma separated list of values. For more information on authenticating clients see the SSHUserAuthRequest event.

The following is a list of methods implemented by the class:

noneThis authentication method is used by most SSH clients to obtain the list of authentication methods available for the user's account. In most cases you should not accept a request using this authentication method.
passwordAuthParam will contain the user-supplied password. If the password is correct, set Accept to true.
publickeyAuthParam will contain an SSH2 public key blob. If the user's public key is acceptable, set Accept to true. The class will then handle verifying the digital signature and will respond to the client accordingly.
keyboard-interactiveSSHUserAuthRequest will fire multiple times for keyboard-interactive authentication: It will fire once for each response sent by the client in the SSH_MSG_USERAUTH_INFO_RESPONSE packet (one for each prompt specified by the daemon). The index of each response will be specified as a suffix in AuthMethod, with AuthParam containing the response to the corresponding prompt (e.g keyboard-interactive-1, keyboard-interactive-2 and so on). Finally, SSHUserAuthRequest will fire one last time with AuthMethod set to "keyboard-interactive" and AuthParam set to an empty string. The daemon must set Accept to true every time to allow the authentication process to succeed.

Data Type


Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks SFTP 2020 C++ Edition - Version 20.0 [Build 8162]