Displaying 20 results from an estimated 32 matches for "thishost".
2024 Jul 01
1
[PATCH RESEND 1/2] Permit %L and %l percent escapes in Include
...*host,
const char *original_host, char *line, const char *filename,
int linenum, int *activep, int flags, int *want_final_pass, int depth)
{
- char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *p;
+ char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *arg_pre, *p;
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
char **cpptr, ***cppptr, fwdarg[256];
u_int i, *uintptr, max_entries = 0;
int r, oactive, negated, opcode, *intptr, value, value2, cmdline = 0;
@@ -1983,6 +1984,12 @@ parse_pubkey_algos:
"command-line option");
goto out;
}
+
+ if (...
2023 Nov 14
1
[PATCH v3 1/2] Permit %L and %l percent escapes in ssh Include
...*host,
const char *original_host, char *line, const char *filename,
int linenum, int *activep, int flags, int *want_final_pass, int depth)
{
- char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *p;
+ char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *arg_pre, *p;
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
char **cpptr, ***cppptr, fwdarg[256];
u_int i, *uintptr, uvalue, max_entries = 0;
int r, oactive, negated, opcode, *intptr, value, value2, cmdline = 0;
@@ -1951,6 +1952,12 @@ parse_pubkey_algos:
"command-line option");
goto out;
}
+...
2023 Dec 20
2
[PATCH RESEND 0/2] Permit %L and %l percent escapes in Include
Using these escapes, the include directive can be crafted to include
differing, host-specific configuration.
Ronan Pigott (2):
Permit %L and %l percent escapes in ssh Include
Permit %L and %l percent escapes in sshd Include
readconf.c | 16 +++++++++++++---
servconf.c | 17 ++++++++++++++---
2 files changed, 27 insertions(+), 6 deletions(-)
base-commit:
2024 Jul 01
2
[PATCH RESEND 0/2] Permit %L and %L percent escapes in Include
Using these escapes, the include directive can be crafted to include
differing, host-specific configuration.
Ronan Pigott (2):
Permit %L and %l percent escapes in Include
Permit %L and %l percent escapes in server Include
readconf.c | 16 +++++++++++++---
servconf.c | 21 ++++++++++++++++-----
2 files changed, 29 insertions(+), 8 deletions(-)
base-commit:
2004 Oct 03
0
[patch] tell user about hosts with same key
...t;host, "%s", hostname);
+ n->next = l;
+ return n;
+}
+
+HostList *
+find_hosts_by_key(const char *filename, const Key *search_key, HostList *initial_hosts)
+{
+ Key *found;
+ FILE *f;
+ char line[8192];
+ int linenum = 0;
+ u_int kbits;
+ char *cp, *cp2;
+ HostList *hostlist;
+ char *thishost = NULL;
+ u_int thishostlen;
+
+ debug3("find_hosts_by_key: filename %s", filename);
+
+ /* Open the file containing the list of known hosts. */
+ f = fopen(filename, "r");
+ if (!f)
+ return initial_hosts;
+
+ hostlist = initial_hosts;
+ found = key_new(search_key->type);
+...
2024 Jul 01
1
[PATCH RESEND 1/2] Permit %L and %l percent escapes in Include
...nst char *original_host, char *line, const char *filename,
> int linenum, int *activep, int flags, int *want_final_pass, int depth)
{
>- char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *p;
>+ char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *arg_pre,
*p;
>+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
> char **cpptr, ***cppptr, fwdarg[256];
> u_int i, *uintptr, max_entries = 0;
> int r, oactive, negated, opcode, *intptr, value, value2, cmdline =
0; @@ -
>1983,6 +1984,12 @@ parse_pubkey_algos:
> "command-line option");
>...
2015 Aug 05
2
[PATCH 1/1] uid for expansion in ControlPath
...nged, 7 insertions(+), 2 deletions(-)
diff --git a/ssh.c b/ssh.c
index 59c1f93..c4de144 100644
--- a/ssh.c
+++ b/ssh.c
@@ -505,7 +505,8 @@ main(int ac, char **av)
{
int i, r, opt, exit_status, use_syslog, config_test = 0;
char *p, *cp, *line, *argv0, buf[PATH_MAX], *host_arg, *logfile;
- char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV];
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV],
+ uidstr[11];
char cname[NI_MAXHOST];
struct stat st;
struct passwd *pw;
@@ -1122,6 +1123,7 @@ main(int ac, char **av)
strlcpy(shorthost, thishost, sizeof(sh...
2023 Nov 13
2
[PATCH v2] Permit %L and %l percent escapes in Include
...*host,
const char *original_host, char *line, const char *filename,
int linenum, int *activep, int flags, int *want_final_pass, int depth)
{
- char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *p;
+ char *str, **charptr, *endofnumber, *keyword, *arg, *arg2, *arg_pre, *p;
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
char **cpptr, ***cppptr, fwdarg[256];
u_int i, *uintptr, uvalue, max_entries = 0;
int r, oactive, negated, opcode, *intptr, value, value2, cmdline = 0;
@@ -1951,6 +1952,12 @@ parse_pubkey_algos:
"command-line option");
goto out;
}
+...
2023 Nov 14
0
[PATCH v3 2/2] Permit %L and %l percent escapes in sshd Include
...th(ServerOptions *options, char *line,
struct connection_info *connectinfo, int *inc_flags, int depth,
struct include_list *includes)
{
- char *str, ***chararrayptr, **charptr, *arg, *arg2, *p, *keyword;
+ char *str, ***chararrayptr, **charptr, *arg, *arg2, *arg_pre, *p, *keyword;
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
int cmdline = 0, *intptr, value, value2, n, port, oactive, r, found;
int ca_only = 0;
SyslogFacility *log_facility_ptr;
@@ -2130,6 +2131,12 @@ process_server_config_line_depth(ServerOptions *options, char *line,
fatal("Include directive not support...
2024 Jul 01
0
[PATCH RESEND 2/2] Permit %L and %l percent escapes in server Include
...s, int depth,
struct include_list *includes)
{
- char *str, ***chararrayptr, **charptr, *arg, *arg2, *p, *keyword;
- int cmdline = 0, *intptr, value, value2, n, port, oactive, r;
- int ca_only = 0, found = 0;
+ char *str, ***chararrayptr, **charptr, *arg, *arg2, *arg_pre, *p, *keyword;
+ char thishost[NI_MAXHOST], shorthost[NI_MAXHOST];
+ int cmdline = 0, *intptr, value, value2, n, port, oactive, r, found;
+ int ca_only = 0;
SyslogFacility *log_facility_ptr;
LogLevel *log_level_ptr;
ServerOpCodes opcode;
@@ -2230,6 +2231,12 @@ process_server_config_line_depth(ServerOptions *options, char *...
2007 Oct 17
2
[patch] ssh.c load_public_identity_files calls getpwuid twice without copy
...+++ openssh-4.4p1-fix/ssh.c 2007-10-17 10:23:07.000000000 -0700
@@ -1252,6 +1252,7 @@
#endif /* SMARTCARD */
if ((pw = getpwuid(original_real_uid)) == NULL)
fatal("load_public_identity_files: getpwuid failed");
+ pw = pwcopy(pw);
if (gethostname(thishost, sizeof(thishost)) == -1)
fatal("load_public_identity_files: gethostname: %s",
strerror(errno));
--
Toby Butzon
2009 Jul 08
4
Feature request: "SetupCommand" invoked before connecting
Hi,
(I'm not subscribed to the list, so please CC me on reply.)
I'd like to request adding a feature to OpenSSH:
Task:
~~~~~
It is quite sometime useful to invoke a program prior to connecting to
an ssh server. The most common use case will probably be port knocking.
That is a small program sends certain packets to a server and the server
reacts to this by unlocking the ssh port, which
2005 Nov 25
1
test failure for openssh-SNAP-20051125.tar.gz
...system.
JGH
-------------- next part --------------
--- openssh.orig/regress/yes-head.sh 2003-09-13 03:21:14.000000000 +0700
+++ openssh/regress/yes-head.sh 2005-11-26 00:44:16.000000000 +0700
@@ -4,7 +4,7 @@
tid="yes pipe head"
for p in 1 2; do
- lines=`${SSH} -$p -F $OBJ/ssh_proxy thishost 'sh -c "while true;do echo yes;done | head -2000"' | (sleep 3 ; wc -l)`
+ lines=`${SSH} -$p -F $OBJ/ssh_proxy thishost 'sh -c "while true;do echo yes;done | (export _POSIX2_VERSION=199209 ; head -2000)"' | (sleep 3 ; wc -l)`
if [ $? -ne 0 ]; then
fail "...
2017 Oct 10
3
tunnel device name acquisition?
Numerous how-tos all over the Internet show how one would set up
a tunnel using ssh, e.g.:
ssh -f -o Tunnel=ethernet <server_ip> true
I was wondering if there's a way to subsequently acquire the names
of the local and remote tun/tap interfaces (e.g., using the default
"-w any:any") for subsequent automatic tunnel configuration, e.g.:
ip link set $TapDev up
ip link set
2013 Oct 18
1
Feedback regarding the ssh(1) Match directive
Hi,
I noticed the recent commit adding Match support to ssh(1). I look
forward to giving it a try, but I have some initial feedback based on
ssh_config.5 and an examiniation of match_cfg_line().
First, the "command" keyword could be a little deceptive. Although the
man page makes the use of this keyword quite clear, my initial
assumption was that the intent was to match against the
2011 Jan 07
1
[RFC/PATCH] ssh: config directive to modify the local environment
...uot;
+
+# reset tid
+tid="localenvmod"
diff --git a/ssh.c b/ssh.c
index 9409fa7..48ba7b2 100644
--- a/ssh.c
+++ b/ssh.c
@@ -751,6 +751,63 @@ main(int ac, char **av)
if (options.control_path != NULL)
muxclient(options.control_path);
+ if (options.num_local_env_mods > 0) {
+ char thishost[NI_MAXHOST];
+
+ if (gethostname(thishost, sizeof(thishost)) == -1)
+ fatal("gethostname: %s", strerror(errno));
+ snprintf(buf, sizeof(buf), "%d", options.port);
+
+ for (i = 0; i < options.num_local_env_mods; i++) {
+ char sepbuf[2], *oldval;
+ int prepend = 0;
+...
2024 Jul 01
1
[PATCH RESEND 1/2] Permit %L and %l percent escapes in Include
July 1, 2024 at 2:47 PM, rsbecker at nexbridge.com wrote:
> Would you be able to document that "thisHost" may be ambiguous, depending on
> the DNS and host resolver configuration? gethostname() is not entirely
> predictable if the localhost has multiple values.
Hm? On linux/glibc, gethostname just uses uname(2). It does not use dns or the
name service switch.
2011 Jan 05
0
[PATCH] fix %n expansion in LocalCommand
...t;h", host, (char *)NULL);
@@ -707,7 +709,7 @@ main(int ac, char **av)
debug3("expanding LocalCommand: %s", options.local_command);
cp = options.local_command;
options.local_command = percent_expand(cp, "d", pw->pw_dir,
- "h", host, "l", thishost, "n", host, "r", options.user,
+ "h", host, "l", thishost, "n", host_arg, "r", options.user,
"p", buf, "u", pw->pw_name, (char *)NULL);
debug3("expanded LocalCommand: %s", options.local_comma...
2010 Jul 13
1
Command output: Failed to write to log file
...77AD at RVEB1SRVMSGCCR1.c
ymru.nhs.uk>
Jul 13 09:41:56 findb postfix/qmgr[15667]: 3B7EF56ABA: from=<>,
size=1711, nrcpt=1 (queue active)
Jul 13 09:41:56 findb postfix/smtpd[15996]: disconnect from
unknown[10.56.85.6]
Jul 13 09:41:56 findb postfix/local[16000]: 3B7EF56ABA:
to=<enduser at thishost.com>, relay=local, delay=0.05,
delays=0.03/0.01/0/0.02, dsn=4.3.0, status=deferred (temporary failure.
Command output: Failed to write to log file)
Our postfix server started logging the above messages so I was thinking
I had a postfix issue, but it turned out that recreating the dovecot.log
fi...
2015 Jul 29
2
[PATCH] ssh: Add option to present certificates on command line
...it_status = compat20 ? ssh_session2() : ssh_session();
packet_close();
@@ -1938,6 +1953,72 @@ ssh_session2(void)
options.escape_char : SSH_ESCAPECHAR_NONE, id);
}
+/* Load certificate file(s) specified in options. */
+static void
+load_certificate_files(void)
+{
+ char *filename, *cp, thishost[NI_MAXHOST];
+ char *pwdir = NULL, *pwname = NULL;
+ struct passwd *pw;
+ int i, n_ids;
+ struct sshkey *cert;
+ char *certificate_files[SSH_MAX_CERTIFICATE_FILES];
+ struct sshkey *certificates[SSH_MAX_CERTIFICATE_FILES];
+
+ n_ids = 0;
+ memset(certificate_files, 0, sizeof(certificate_files));
+...