Installation
<<<
tcpwrap_check Référence des fonctions
>>>

8.122 Fonctions TCP Wrappers
8 Référence des fonctions
 Manuel PHP

Introduction
Installation
->tcpwrap_check

8.122.3 tcpwrap_check()Vérification Tcpwrap

[ Exemples avec tcpwrap_check ]   CVS uniquement

bool  tcpwrap_check ( string   daemon , string   address , string   user , bool   nodns )

tcpwrap_check consulte les fichiers /etc/hosts.allow et /etc/hosts.deny pour vérifier si l'accès au service daemon est permis ou pas pour un client.

    daemon
    Le nom du service.
    address
    L'adresse distante du client. Peut être soit une adresse IP, soit un nom de domaine.
    user
    Un nom d'utilisateur, optionnel.
    nodns
    Si address ressemble à un nom de domaine, DNS est utilisé pour le résoudre en adresse IP ; définissez nodns à TRUE pour éviter ce comportement.

Cette fonction retourne TRUE si l'accès doit être autorisé, FALSE sinon.

Refuser toutes les connexions depuis localhost

Si votre fichier /etc/hosts.deny contient :

Pour plus de détails, consultez la page man de hosts_access(3).

<< tcpwrap_check >>
Installation Fonctions TCP Wrappers Référence des fonctions