Sponsored Content
Full Discussion: SSHD does not start
Operating Systems AIX SSHD does not start Post 302156470 by Neo on Tuesday 8th of January 2008 07:41:07 AM
Old 01-08-2008
Quote:
Originally Posted by untamed
Code:
getnameinfo failed: Invalid argument
getnameinfo failed: Invalid argument
Cannot bind any address.

You have a DNS problem (host name, IP address, name-IP resolution), it seems.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

sshd

i just downloaded and installed succesfully openssh server, and am running it on netbsd 1.5, i can not login with anyuser, i enabled root login just to see what happens and i can login as root, but no other user, i checked my config and most things are default, whats going on? has any one else had... (2 Replies)
Discussion started by: norsk hedensk
2 Replies

2. AIX

sshd restart

need some clarification: if i ssh to the server & i restart the sshd process, did my connection gone? one more thing, there are a few sshd processes in aix, how do i restart it all to read new config? using HUP? thanks in advance! (2 Replies)
Discussion started by: ashterix
2 Replies

3. AIX

It helps in the sshd on sshd.log

Friends, I made the installation of the ssh in the it conspires, I configured in the ssh_config the following parameters.. SyslogFacility AUTH LogLevel INFO that should generate sshd.log in the /var/log.... more no this generating. Somebody could help myself in... (0 Replies)
Discussion started by: sandba
0 Replies

4. UNIX for Advanced & Expert Users

sshd deamon issue !!!!

On one of my production server sshd process is running on top . consuming 100 % amount of CPU . Below is the output of the sshd process... Please advice I am not sure what should I be doing about this. Can I kill the process ? ... Thanking you in advance. CPU TTY PID USERNAME PRI NI SIZE ... (1 Reply)
Discussion started by: kpatel786
1 Replies

5. UNIX for Dummies Questions & Answers

sshd question

Can someone tell me the difference between the (2) listed below: oracle pts/1 ip1 May1 7:11 9:11 oracle sshd ip1 May1 7:11 8:22 How do I read the above information, the fact that the row for pts/1 has a longer time duration than the row for sshd. Why is the... (2 Replies)
Discussion started by: banyan
2 Replies

6. Solaris

no sshd log

My ssh log appear to the screen which i want it to be log to /var/log/sshd.log how to log the sshd to /var/log? (5 Replies)
Discussion started by: hezry79
5 Replies

7. Solaris

sshd not able to restart

Hi, I was able to putty a few server (Solaris 10) of mine using hostname, but when i change to ip address, it shows login as: root Using keyboard-interactive authentication. Password: Access denied I change PermitRootLogin to yes. I tried to do a sshd restart, however ... (6 Replies)
Discussion started by: beginningDBA
6 Replies

8. Solaris

sshd and loginlog

I have shamelessly tried all the possible ways to see if my /var/adm/loginlog logs user access entries for ssh but nothing has worked for me so far..:confused: for telnet login its working fine. Adding auth.info in syslog.conf works but i dont want that output. Is there any way to edit... (2 Replies)
Discussion started by: ningy
2 Replies

9. Solaris

pam sshd error

Hi I wanted to convert my pam libraries to 64 bit. so recently compiled my pam_banner and pam_wheel to 64 bit. I got the following error... sshd: dlsym failed pam_sm_authenticate:error ld.so.1 : sshd fatal: pam_sm_authenticate: can't find symbol thnaks (8 Replies)
Discussion started by: chinchao
8 Replies

10. Red Hat

Sshd - error

Hi, Do you know what cause the error message ? Nov 19 13:42:19 cfsasnd02 sshd: pam_env(sshd:setcred): non-alphanumeric key '-- /etc/environment' in /etc/environment', ignoring Nov 19 13:42:20 cfsasnd02 sshd: pam_env(sshd:setcred): non-alphanumeric key '-- /etc/environment' in... (0 Replies)
Discussion started by: xitrum
0 Replies
GETNAMEINFO(3)						   BSD Library Functions Manual 					    GETNAMEINFO(3)

NAME
getnameinfo -- socket address structure to hostname and service name SYNOPSIS
#include <netdb.h> int getnameinfo(const struct sockaddr * restrict sa, socklen_t salen, char * restrict host, size_t hostlen, char * restrict serv, size_t servlen, int flags); DESCRIPTION
The getnameinfo() function is used to convert a sockaddr structure to a pair of host name and service strings. It is a replacement for and provides more flexibility than the gethostbyaddr(3) and getservbyport(3) functions and is the converse of the getaddrinfo(3) function. The sockaddr structure sa should point to either a sockaddr_in or sockaddr_in6 structure (for IPv4 or IPv6 respectively) that is salen bytes long. The host and service names associated with sa are stored in host and serv which have length parameters hostlen and servlen. The maximum value for hostlen is NI_MAXHOST and the maximum value for servlen is NI_MAXSERV, as defined by <netdb.h>. If a length parameter is zero, no string will be stored. Otherwise, enough space must be provided to store the host name or service string plus a byte for the NUL terminator. The flags argument is formed by OR'ing the following values: NI_NOFQDN A fully qualified domain name is not required for local hosts. The local part of the fully qualified domain name is returned instead. NI_NUMERICHOST Return the address in numeric form, as if calling inet_ntop(3), instead of a host name. NI_NAMEREQD A name is required. If the host name cannot be found in DNS and this flag is set, a non-zero error code is returned. If the host name is not found and the flag is not set, the address is returned in numeric form. NI_NUMERICSERV The service name is returned as a digit string representing the port number. NI_DGRAM Specifies that the service being looked up is a datagram service, and causes getservbyport(3) to be called with a second argument of ``udp'' instead of its default of ``tcp''. This is required for the few ports (512-514) that have different services for UDP and TCP. This implementation allows numeric IPv6 address notation with scope identifier, as documented in chapter 11 of draft-ietf-ipv6-scoping- arch-02.txt. IPv6 link-local address will appear as a string like ``fe80::1%ne0''. Refer to getaddrinfo(3) for more information. RETURN VALUES
getnameinfo() returns zero on success or one of the error codes listed in gai_strerror(3) if an error occurs. EXAMPLES
The following code tries to get a numeric host name, and service name, for a given socket address. Observe that there is no hardcoded refer- ence to a particular address family. struct sockaddr *sa; /* input */ char hbuf[NI_MAXHOST], sbuf[NI_MAXSERV]; if (getnameinfo(sa, sa->sa_len, hbuf, sizeof(hbuf), sbuf, sizeof(sbuf), NI_NUMERICHOST | NI_NUMERICSERV)) { errx(1, "could not get numeric hostname"); /*NOTREACHED*/ } printf("host=%s, serv=%s ", hbuf, sbuf); The following version checks if the socket address has a reverse address mapping: struct sockaddr *sa; /* input */ char hbuf[NI_MAXHOST]; if (getnameinfo(sa, sa->sa_len, hbuf, sizeof(hbuf), NULL, 0, NI_NAMEREQD)) { errx(1, "could not resolve hostname"); /*NOTREACHED*/ } printf("host=%s ", hbuf); SEE ALSO
gai_strerror(3), getaddrinfo(3), gethostbyaddr(3), getservbyport(3), inet_ntop(3), resolver(3), hosts(5), resolv.conf(5), services(5), hostname(7), named(8) R. Gilligan, S. Thomson, J. Bound, and W. Stevens, Basic Socket Interface Extensions for IPv6, RFC 2553, March 1999. S. Deering, B. Haberman, T. Jinmei, E. Nordmark, and B. Zill, IPv6 Scoped Address Architecture, internet draft, draft-ietf-ipv6-scoping- arch-02.txt, work in progress material. Craig Metz, "Protocol Independence Using the Sockets API", Proceedings of the FREENIX track: 2000 USENIX annual technical conference, June 2000. STANDARDS
The getnameinfo() function is defined by the IEEE Std 1003.1g-2000 (``POSIX.1'') draft specification and documented in RFC 2553, ``Basic Socket Interface Extensions for IPv6''. CAVEATS
getnameinfo() can return both numeric and FQDN forms of the address specified in sa. There is no return value that indicates whether the string returned in host is a result of binary to numeric-text translation (like inet_ntop(3)), or is the result of a DNS reverse lookup. Because of this, malicious parties could set up a PTR record as follows: 1.0.0.127.in-addr.arpa. IN PTR 10.1.1.1 and trick the caller of getnameinfo() into believing that sa is 10.1.1.1 when it is actually 127.0.0.1. To prevent such attacks, the use of NI_NAMEREQD is recommended when the result of getnameinfo() is used for access control purposes: struct sockaddr *sa; socklen_t salen; char addr[NI_MAXHOST]; struct addrinfo hints, *res; int error; error = getnameinfo(sa, salen, addr, sizeof(addr), NULL, 0, NI_NAMEREQD); if (error == 0) { memset(&hints, 0, sizeof(hints)); hints.ai_socktype = SOCK_DGRAM; /*dummy*/ hints.ai_flags = AI_NUMERICHOST; if (getaddrinfo(addr, "0", &hints, &res) == 0) { /* malicious PTR record */ freeaddrinfo(res); printf("bogus PTR record "); return -1; } /* addr is FQDN as a result of PTR lookup */ } else { /* addr is numeric string */ error = getnameinfo(sa, salen, addr, sizeof(addr), NULL, 0, NI_NUMERICHOST); } BUGS
The implementation of getnameinfo() is not thread-safe. BSD
March 21, 2005 BSD
All times are GMT -4. The time now is 07:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy