mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-06-30 19:12:48 -05:00
Start of an SSH-server-specific config structure.
This is much simpler than Conf, because I don't expect to have to copy it around, load or save it to disk (or the Windows registry), or serialise it between processes. So it can be a straightforward struct. As yet there's nothing actually _in_ it. I've just created the structure and arranged to pass it through to all the SSH layers. But now it's here, it will be a place I can add configuration items as I find I need them.
This commit is contained in:
@ -366,6 +366,7 @@ int main(int argc, char **argv)
|
||||
RSAKey *hostkey1 = NULL;
|
||||
|
||||
AuthPolicy ap;
|
||||
SshServerConfig ssc;
|
||||
|
||||
Conf *conf = conf_new();
|
||||
load_open_settings(NULL, conf);
|
||||
@ -374,6 +375,8 @@ int main(int argc, char **argv)
|
||||
ap.ssh1keys = NULL;
|
||||
ap.ssh2keys = NULL;
|
||||
|
||||
memset(&ssc, 0, sizeof(ssc));
|
||||
|
||||
if (argc <= 1) {
|
||||
/*
|
||||
* We're going to terminate with an error message below,
|
||||
@ -548,7 +551,7 @@ int main(int argc, char **argv)
|
||||
|
||||
{
|
||||
Plug *plug = ssh_server_plug(
|
||||
conf, hostkeys, nhostkeys, hostkey1, &ap, server_logpolicy,
|
||||
conf, &ssc, hostkeys, nhostkeys, hostkey1, &ap, server_logpolicy,
|
||||
&unix_live_sftpserver_vt);
|
||||
ssh_server_start(plug, make_fd_socket(0, 1, -1, plug));
|
||||
}
|
||||
|
Reference in New Issue
Block a user