madko
Pour ouvrir le port avec firewalld:
firewall-cmd --add-port=25565/tcp
si ça marche, pour rendre l'ouverture permanente, même ligne avec l'option --permanent:
firewall-cmd --add-port=25565/tcp --permanent
Enfin:
iptables -L -n -v
devrait faire apparaitre ce port.
mtxrider
après iptables -L -n -v j'obtiens ça :
[root@servnux eform]# iptables -L -n -v
Chain INPUT (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination
1304 1137K ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate RELATED,ESTABLISHED
0 0 ACCEPT all -- lo * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_direct all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 ACCEPT icmp -- * * 0.0.0.0/0 0.0.0.0/0
9 360 DROP all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate INVALID
25 828 REJECT all -- * * 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination
0 0 ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate RELATED,ESTABLISHED
0 0 ACCEPT all -- lo * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_direct all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_IN_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_IN_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_OUT_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_OUT_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 ACCEPT icmp -- * * 0.0.0.0/0 0.0.0.0/0
0 0 DROP all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate INVALID
0 0 REJECT all -- * * 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT 868 packets, 54094 bytes)
pkts bytes target prot opt in out source destination
1410 132K OUTPUT_direct all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FORWARD_IN_ZONES (1 references)
pkts bytes target prot opt in out source destination
0 0 FWDI_FedoraWorkstation all -- enp0s25 * 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 FWDI_FedoraWorkstation all -- + * 0.0.0.0/0 0.0.0.0/0 [goto]
Chain FORWARD_IN_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain FORWARD_OUT_ZONES (1 references)
pkts bytes target prot opt in out source destination
0 0 FWDO_FedoraWorkstation all -- * enp0s25 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 FWDO_FedoraWorkstation all -- * + 0.0.0.0/0 0.0.0.0/0 [goto]
Chain FORWARD_OUT_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain FORWARD_direct (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
0 0 FWDI_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDI_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDI_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FWDI_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
0 0 FWDO_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDO_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDO_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FWDO_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain INPUT_ZONES (1 references)
pkts bytes target prot opt in out source destination
114 19608 IN_FedoraWorkstation all -- enp0s25 * 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 IN_FedoraWorkstation all -- + * 0.0.0.0/0 0.0.0.0/0 [goto]
Chain INPUT_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain INPUT_direct (1 references)
pkts bytes target prot opt in out source destination
Chain IN_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
114 19608 IN_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 IN_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 IN_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain IN_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
59 15805 ACCEPT udp -- * * 0.0.0.0/0 224.0.0.251 udp dpt:5353 ctstate NEW
13 1140 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpt:137 ctstate NEW
4 960 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpt:138 ctstate NEW
0 0 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:22 ctstate NEW
3 405 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpts:1025:65535 ctstate NEW
1 110 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpts:1025:65535 ctstate NEW
0 0 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:25565 ctstate NEW
Chain IN_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain IN_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain OUTPUT_direct (1 references)
pkts bytes target prot opt in out source destination
[root@servnux eform]# clear
[3;J
[root@servnux eform]# iptables -L -n -v
Chain INPUT (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination
1310 1138K ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate RELATED,ESTABLISHED
0 0 ACCEPT all -- lo * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_direct all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 INPUT_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 ACCEPT icmp -- * * 0.0.0.0/0 0.0.0.0/0
9 360 DROP all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate INVALID
25 828 REJECT all -- * * 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination
0 0 ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate RELATED,ESTABLISHED
0 0 ACCEPT all -- lo * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_direct all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_IN_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_IN_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_OUT_ZONES_SOURCE all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FORWARD_OUT_ZONES all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 ACCEPT icmp -- * * 0.0.0.0/0 0.0.0.0/0
0 0 DROP all -- * * 0.0.0.0/0 0.0.0.0/0 ctstate INVALID
0 0 REJECT all -- * * 0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT 873 packets, 55348 bytes)
pkts bytes target prot opt in out source destination
1415 133K OUTPUT_direct all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FORWARD_IN_ZONES (1 references)
pkts bytes target prot opt in out source destination
0 0 FWDI_FedoraWorkstation all -- enp0s25 * 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 FWDI_FedoraWorkstation all -- + * 0.0.0.0/0 0.0.0.0/0 [goto]
Chain FORWARD_IN_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain FORWARD_OUT_ZONES (1 references)
pkts bytes target prot opt in out source destination
0 0 FWDO_FedoraWorkstation all -- * enp0s25 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 FWDO_FedoraWorkstation all -- * + 0.0.0.0/0 0.0.0.0/0 [goto]
Chain FORWARD_OUT_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain FORWARD_direct (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
0 0 FWDI_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDI_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDI_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FWDI_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain FWDI_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
0 0 FWDO_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDO_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
0 0 FWDO_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain FWDO_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain FWDO_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain INPUT_ZONES (1 references)
pkts bytes target prot opt in out source destination
114 19608 IN_FedoraWorkstation all -- enp0s25 * 0.0.0.0/0 0.0.0.0/0 [goto]
0 0 IN_FedoraWorkstation all -- + * 0.0.0.0/0 0.0.0.0/0 [goto]
Chain INPUT_ZONES_SOURCE (1 references)
pkts bytes target prot opt in out source destination
Chain INPUT_direct (1 references)
pkts bytes target prot opt in out source destination
Chain IN_FedoraWorkstation (2 references)
pkts bytes target prot opt in out source destination
114 19608 IN_FedoraWorkstation_log all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 IN_FedoraWorkstation_deny all -- * * 0.0.0.0/0 0.0.0.0/0
114 19608 IN_FedoraWorkstation_allow all -- * * 0.0.0.0/0 0.0.0.0/0
Chain IN_FedoraWorkstation_allow (1 references)
pkts bytes target prot opt in out source destination
59 15805 ACCEPT udp -- * * 0.0.0.0/0 224.0.0.251 udp dpt:5353 ctstate NEW
13 1140 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpt:137 ctstate NEW
4 960 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpt:138 ctstate NEW
0 0 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:22 ctstate NEW
3 405 ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 udp dpts:1025:65535 ctstate NEW
1 110 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpts:1025:65535 ctstate NEW
0 0 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:25565 ctstate NEW
Chain IN_FedoraWorkstation_deny (1 references)
pkts bytes target prot opt in out source destination
Chain IN_FedoraWorkstation_log (1 references)
pkts bytes target prot opt in out source destination
Chain OUTPUT_direct (1 references)
pkts bytes target prot opt in out source destination
et je n'arrive pas à me connecté (soit encore un problème de port ou de translation d'adresse au niveau du routeur, je n'arrive pas à savoir)
mtxrider
précision, si j'attaque l'ip locale avec MC, ça fonctionne.
Mais pas en distant.
l'adresse ip est :
109.190.193.221
Comme elle est dynamique, j'ai fais un no-ip :
bindcraft.no-ip.info
Et pour finir, un alias depuis le site de ma boite qui renvoit sur le no ip :
minecraft.e-forminfo.fr
Quand je ping tout ça depuis l'extérieur, j'ai un ping pas très gros (pfiou je pensais que ça allait être pire), et j'obtiens l'ip de ma boxe dynamique.
Je remarque maintenant que le ping de l'alias en dernier ne marche pas / plus.
Mais ça, c'est un autre problème que je résoudrais plus tard, et s'il faut je me passerais de cette redirection.
mtxrider
Pour en revenir à nos mouton, je ne peux pas me connecté rien qu'avec l'ip
madko
Donc le ping valide que ta box répond. As tu fais un tcpdump quand tu tente de te connecter à ton serveur depuis l'exterieur? Car si tu ne vois rien passer sur ton serveur c'est donc la box qui redirige pas le port 25565
mtxrider
je vais faire un tcpdump la, j'avais pas compris que sa devait être visible QUAND j'essaye de me connecté, en même temps je suis bête ça parrait logique.
Ce qui me parrait bizarre, j'ai pris un vieux netbook sous windows 7, poser un serveur minecraft dessus rapidement, redigier le flux depuis la box sur ce pc au lieux de mon serveur, et la, magie, ça passe !
mtxrider
Je n'ai rien avec tcpdump, il ne voit rien passer sur ce port ... je fais quoi ? :s
mtxrider
j'ai activer le journal de connexion sur ma box, qui doit enregistrer les connexion de cette redirection de port, je vais voir si je vois passer qq chose
mtxrider
j'ai utiliser ping.eu plutot que tcpdump, ça ne donnait rien.
quand j'utilise ping.eu en mode teste de port et que je lui donne le 25565
dans le journal je vois ça :
FIREWALL rule : Protocol: TCP Src ip: 88.198.46.51 Src port: 41874 Dst ip: 192.168.0.13 Dst port: 25565 Chain: forward_host_service Rule Id: 1 Action: accept
si je comprends bien, ça veux dire, bon bah laisse passer ! y'a un feu vert à coté de ce message donc j'en conclu que c'est quand même fedora ...
madko
si le tcpdump ne voit rien arriver c'est que rien arrive sur Fedora (y compris son parefeu). Donc a part la box je vois pas trop ce que ça pourrait être. Vu le message il laisse passer vers 192.168.0.13 port 25565, 192.168.0.13 c'est bien l'adresse de ta fedora?
mtxrider
oui :s
je vois que t'es aussi chez ovh adsl, tu fais du routage ? t'as quoi comme modem ?
j'ai le technicolor TG788vn v2.
Et comme dit, si je fait la translation vers un poste windows avec un serveur tout con, ça fonctionne ...*
Je ne souhaite pas me passer du firewall, mais outre couper le service, il n'y à rien d'autre à faire pour tester ?
mtxrider
Au fait, honnorer de rencontrer la personne à l'origine de darktable, que j'utilise quelque fois, un grand merci
mtxrider
Et au passage, tcpdump voit passer le traffique quand je suis co en local, pas quand ça vient de l'extérieur.
Serait-ce une bonne idée de tester firewall off ?
madko
Tu peux en effet couper le firewall mais ça n'a pas d'impact sur tcpdump, qui voit le trafic arriver et ne pas avoir de réponse par ex si le parefeu genait. tcpdump écoute tout ce qui passe avant que ça arrive au parefeu.
Mais bon ça coute rien d'essayer:
systemctl stop firewalld
J'avais le TG788vn v2 avant, et j'en ai pas garder un super bon souvenir, c'était pas terrible à configurer. Après je sais pas si c'est plus simple via l'interface de configuration du modem, de configurer une DMZ et d'y mettre l'ip de ta machine Fedora, plutot que de faire qu'une seule redirection de port. A voir.
mtxrider
Peut être pas bête, mais il n'y à plus le doublage du pare-feu de la box + fedora au final, je perds quand même en sécurité.
Ok ok, je ne note ce qui concerne TCP dump, je pensais vraiment que s'était justement la pour capté ce qui passe derrière le pare-feu.
A mon sens, pour avoir plus d'info la, je pense tout doucement que ça vient bien du modem.
Quand je lui fait faire le routage de port sur mon netbook ça marche.
Maintenant fédora ne voit rien venir quand c'est vers lui que le routage s'effectue.
ça veut probablement dire que, même si le modem me dit " ça passe " qu'il ne laisse rien passer finalement.
tcpdump le prouve même.
Je vais voir ce que je fais et réfléchir, je te tiens au courant.
madko
Le truc à tester, c'est de faire le routage vers ton poste windows, et de verifier que ça marche. Normalement ça tu disais que ça marchait.
Ensuite tu éteins ta machine windows, et tu lui pique son IP pour la mettre sur ta Fedora. Et tu vois si ça marche toujours. Au moins ça evite de refaire une conf sur le modem qui s'y ça se trouve à besoin d'un certain temps pour oublier qu'il doit diriger le port vers l'IP de ton windows pour l'ip de ta fedora.
Peut être aussi que sous Windows avec l'UPNP celui-ci demande à ton modem de rediriger les flux vers son IP. Donc ça expliquerait pourquoi ça marche pour Windows, et jamais pour ta Fedora. Ce serait une autre piste, désactiver l'UPNP sur la box OVH (c'est jamais bon l'UPNP).
mtxrider
J'ai pas eu besoin de rien ...
J'ai démarrer mon serveur ce matin, et ça fonctionne ...
A n'y rien comprendre, je l'ai redémarrer plusieurs fois et tout est ok.
Merci du temps passer et perdu pour m'avoir aider ...
Bonne journée.