Contenu | Rechercher | Menus

Annonce

Si vous avez des soucis pour rester connecté, déconnectez-vous puis reconnectez-vous depuis ce lien en cochant la case
Me connecter automatiquement lors de mes prochaines visites.

À propos de l'équipe du forum.

#1 Le 01/03/2018, à 22:30

MasGames11

Ports bloqués serveur de jeux

Salut,

J'ai un souci au niveau du pare-feu sur mes serveurs de jeux, il y a certains ports qui sont bloqués et d'autres non, donc ce que j'ai fait c'est que j'ai ouvert une plage de ports mais ça ne fonctionnait toujours pas, du coup j'ai désactivé iptables mais les ports sont toujours bloqués. Mais je me suis rendu compte que quand je me connectais sur putty, FTP, WEB  etc. je pouvais accéder à mes serveurs de jeux, mais uniquement moi pourquoi ?.

Pourtant j'ai désactivé iptables, mais je pense que ça viens surement d'autre chose mais de quoi, je ne sais pas ;(

Merci de votre aide.

Hors ligne

#2 Le 02/03/2018, à 08:37

bruno

Re : Ports bloqués serveur de jeux

Bonjour,

Où se situe ton serveur ? Dans un data center, derrière une box ? Quelle version d'Ubuntu ? Comment as-tu « désactivé » iptables ?

Hors ligne

#3 Le 02/03/2018, à 10:33

MasGames11

Re : Ports bloqués serveur de jeux

Bonjour,

Je suis en housing.
Version ubuntu 16.04.
J'ai pas vraiment désactiver, mais enlever toutes les règle avec cette commande par exemple: iptables -F

Merci.

Hors ligne

#4 Le 02/03/2018, à 10:48

bruno

Re : Ports bloqués serveur de jeux

Sur le serveur, regarder les règles iptables :

sudo iptables -n -L

et si IPv6 :

sudo ip6tables -n -L

regarder les services en écoute :

sudo netstat -tunlp

regarder les éventuels blocages par hôte :

cat /etc/hosts.deny
cat /etc/hosts.allow

Dernière modification par bruno (Le 02/03/2018, à 12:46)

Hors ligne

#5 Le 02/03/2018, à 17:51

MasGames11

Re : Ports bloqués serveur de jeux

Voilà ce qui m'affiche, une idée ?:

root@server:~# sudo iptables -n -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination
root@serveur:~# sudo netstat -tunlp
Connexions Internet actives (seulement serveurs)
Proto Recv-Q Send-Q Adresse locale          Adresse distante        Etat       P                                                                                        ID/Program name
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN                                                                                              1265/sshd
tcp        0      0 127.0.0.1:631           0.0.0.0:*               LISTEN                                                                                              18187/cupsd
tcp        0      0 0.0.0.0:119             0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:1080            0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN                                                                                              2148/sendmail: MTA:
tcp        0      0 0.0.0.0:25465           0.0.0.0:*               LISTEN                                                                                              1491/multicraft
tcp        0      0 0.0.0.0:12345           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:12346           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:635             0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:49724           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:540             0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 127.0.1.1:25565         0.0.0.0:*               LISTEN                                                                                              2967/srcds_linux
tcp        0      0 0.0.0.0:1               0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:20034           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:32771           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:32772           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:40421           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:32773           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:32774           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 10.8.0.2:27015          0.0.0.0:*               LISTEN                                                                                              3024/srcds_linux
tcp        0      0 0.0.0.0:31337           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 127.0.0.1:3306          0.0.0.0:*               LISTEN                                                                                              1280/mysqld
tcp        0      0 127.0.0.1:587           0.0.0.0:*               LISTEN                                                                                              2148/sendmail: MTA:
tcp        0      0 0.0.0.0:6667            0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:11              0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:5742            0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:143             0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:111             0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:79              0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:15              0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:54320           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:2000            0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:27665           0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 0.0.0.0:1524            0.0.0.0:*               LISTEN                                                                                              1318/portsentry
tcp        0      0 127.0.1.1:53            0.0.0.0:*               LISTEN                                                                                              1748/dnsmasq
tcp        0      0 0.0.0.0:21              0.0.0.0:*               LISTEN                                                                                              1491/multicraft
tcp6       0      0 :::22                   :::*                    LISTEN                                                                                              1265/sshd
tcp6       0      0 ::1:631                 :::*                    LISTEN                                                                                              18187/cupsd
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::443                  :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::298                  :::*                    LISTEN                                                                                              1982/java
tcp6       0      0 :::299                  :::*                    LISTEN                                                                                              1982/java
tcp6       0      0 :::8080                 :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::80                   :::*                    LISTEN                                                                                              2232/apache2
tcp6       0      0 :::25585                :::*                    LISTEN                                                                                              1519/java
udp        0      0 0.0.0.0:25565           0.0.0.0:*                                                                                                                   2967/srcds_linux
udp        0      0 0.0.0.0:26901           0.0.0.0:*                                                                                                                   2967/srcds_linux
udp        0      0 10.8.0.2:26902          0.0.0.0:*                                                                                                                   3024/srcds_linux
udp        0      0 0.0.0.0:27005           0.0.0.0:*                                                                                                                   2967/srcds_linux
udp        0      0 10.8.0.2:27006          0.0.0.0:*                                                                                                                   3024/srcds_linux
udp        0      0 10.8.0.2:27015          0.0.0.0:*                                                                                                                   3024/srcds_linux
udp        0      0 0.0.0.0:27020           0.0.0.0:*                                                                                                                   2967/srcds_linux
udp        0      0 10.8.0.2:27021          0.0.0.0:*                                                                                                                   3024/srcds_linux
udp        0      0 0.0.0.0:31335           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:31337           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:32770           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:32771           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:32772           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:32773           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:32774           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:34555           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:37444           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:40293           0.0.0.0:*                                                                                                                   1930/openvpn
udp        0      0 0.0.0.0:47047           0.0.0.0:*                                                                                                                   1748/dnsmasq
udp        0      0 0.0.0.0:54321           0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:56430           0.0.0.0:*                                                                                                                   1020/avahi-daemon:
udp        0      0 0.0.0.0:1               0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:7               0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:9               0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 127.0.1.1:53            0.0.0.0:*                                                                                                                   1748/dnsmasq
udp        0      0 0.0.0.0:68              0.0.0.0:*                                                                                                                   1462/dhclient
udp        0      0 0.0.0.0:69              0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 10.8.0.2:123            0.0.0.0:*                                                                                                                   2484/ntpd
udp        0      0 192.168.100.198:123     0.0.0.0:*                                                                                                                   2484/ntpd
udp        0      0 127.0.0.1:123           0.0.0.0:*                                                                                                                   2484/ntpd
udp        0      0 0.0.0.0:123             0.0.0.0:*                                                                                                                   2484/ntpd
udp        0      0 0.0.0.0:161             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:162             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:513             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:631             0.0.0.0:*                                                                                                                   1102/cups-browsed
udp        0      0 0.0.0.0:635             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:640             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:641             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:700             0.0.0.0:*                                                                                                                   1323/portsentry
udp        0      0 0.0.0.0:5353            0.0.0.0:*                                                                                                                   1020/avahi-daemon:
udp6       0      0 :::60398                :::*                                                                                                                        1020/avahi-daemon:
udp6       0      0 fe80::cc1a:1b37:2bf:123 :::*                                                                                                                        2484/ntpd
udp6       0      0 ::1:123                 :::*                                                                                                                        2484/ntpd
udp6       0      0 :::123                  :::*                                                                                                                        2484/ntpd
udp6       0      0 :::5353                 :::*                                                                                                                        1020/avahi-daemon:
Vous avez du nouveau courrier dans /var/mail/root
root@server:~# cat /etc/hosts.deny
# /etc/hosts.deny: list of hosts that are _not_ allowed to access the system.
#                  See the manual pages hosts_access(5) and hosts_options(5).
#
# Example:    ALL: some.host.name, .some.domain
#             ALL EXCEPT in.fingerd: other.host.name, .other.domain
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#
# The PARANOID wildcard matches any host whose name does not match its
# address.
#
# You may wish to enable this to ensure any programs that don't
# validate looked up hostnames still leave understandable logs. In past
# versions of Debian this has been the default.
# ALL: PARANOID

root@server:~# cat /etc/hosts.allow
sendmail: all
# /etc/hosts.allow: list of hosts that are allowed to access the system.
#                   See the manual pages hosts_access(5) and hosts_options(5).
#
# Example:    ALL: LOCAL @some_netgroup
#             ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#

Merci.

Hors ligne

#6 Le 02/03/2018, à 18:16

bruno

Re : Ports bloqués serveur de jeux

Pas d'idée, sauf portsentry mal configuré qui pourrait bloquer.

Hors ligne