Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > de.comp.lang.python > #5513
| From | Ulli Horlacher <framstag@rus.uni-stuttgart.de> |
|---|---|
| Newsgroups | de.comp.lang.python |
| Subject | socket.create_connection() ipv4 oder ipv6? |
| Date | 2019-06-25 10:11 +0000 |
| Organization | University of Stuttgart, FRG |
| Message-ID | <qess02$t26$1@news2.informatik.uni-stuttgart.de> (permalink) |
Mit
sock = socket.create_connection(('flupp.belwue.de',591))
bekomme ich einen tcp Link. Das funktioniert.
In der Doku steht dazu:
https://docs.python.org/3/library/socket.html
Connect to a TCP service listening on the Internet address (a 2-tuple
(host, port)), and return the socket object. This is a higher-level
function than socket.connect(): if host is a non-numeric hostname, it
will try to resolve it for both AF_INET and AF_INET6, and then try to
connect to all possible addresses in turn until a connection succeeds.
flupp.belwue.de hat sowohl ipv4 als auch ipv6 Adresse.
Welche wird genommen und warum?
--
Ullrich Horlacher Server und Virtualisierung
Rechenzentrum TIK
Universitaet Stuttgart E-Mail: horlacher@tik.uni-stuttgart.de
Allmandring 30a Tel: ++49-711-68565868
70569 Stuttgart (Germany) WWW: http://www.tik.uni-stuttgart.de/
Back to de.comp.lang.python | Previous | Next — Next in thread | Find similar
socket.create_connection() ipv4 oder ipv6? Ulli Horlacher <framstag@rus.uni-stuttgart.de> - 2019-06-25 10:11 +0000
Re: socket.create_connection() ipv4 oder ipv6? "Peter Heitzer" <peter.heitzer@rz.uni-regensburg.de> - 2019-06-25 10:29 +0000
Re: socket.create_connection() ipv4 oder ipv6? Ulli Horlacher <framstag@rus.uni-stuttgart.de> - 2019-06-25 13:16 +0000
Re: [Python-de] socket.create_connection() ipv4 oder ipv6? Julian Gethmann <mail.python.org@gethmann.org> - 2019-06-25 15:42 +0200
Re: [Python-de] socket.create_connection() ipv4 oder ipv6? Ulli Horlacher <framstag@rus.uni-stuttgart.de> - 2019-06-25 15:46 +0000
Re: socket.create_connection() ipv4 oder ipv6? Florian Weimer <fw@deneb.enyo.de> - 2019-06-29 21:02 +0200
Re: socket.create_connection() ipv4 oder ipv6? Ulli Horlacher <framstag@rus.uni-stuttgart.de> - 2019-06-29 20:21 +0000
csiph-web