Bonjour,
Je suis en train de mettre en place un tunnel VPN net-to-net entre 2 site distants, avec 2 ipcop 1.4.21:
Au niveau configuration des RPVs, je pense que tout est OK.
Je constate que la machine sur le site A crée une interface ipsec0 avec comme MAC celle de la patte GREEN
Je constate que la machine sur le site B crée une interface ipsec0 avec comme MAC celle de la patte RED
De plus, voici les logs de la machine A (j'ai mis en couleur les lignes qui pour moi semblent être la source du probleme
14:50:39 ipsec__plutorun ...could not start conn "test"
14:50:39 ipsec__plutorun 022 "test": we have no ipsecN interface for either end of this connecti on
14:50:39 pluto[9356] "test": we have no ipsecN interface for either end of this connection
14:50:39 ipsec__plutorun ...could not route conn "test"
14:50:39 ipsec__plutorun 022 "test": we have no ipsecN interface for either end of this connecti on
14:50:39 pluto[9356] loading secrets from "/etc/ipsec.secrets"
14:50:39 pluto[9356] adding interface ipsec0/eth0 192.168.16.114:4500
14:50:39 pluto[9356] adding interface ipsec0/eth0 192.168.16.114
14:50:39 pluto[9356] listening for IKE messages
14:50:39 pluto[9356] added connection description "test"
14:50:39 pluto[9356] | from whack: got --ike=aes128-sha-modp1536,aes128-sha-modp1024,aes128-md5-modp1 536,aes128-md5-modp1024,3des-sha-modp1536,3des-sha-modp1024,3des-md5-modp1536,3d es-md5-modp1024
14:50:39 pluto[9356] | from whack: got --esp=aes128-sha1,aes128-md5,3des-sha1,3des-md5
14:50:39 pluto[9356] OpenPGP certificate file '/etc/pgpcert.pgp' not found
14:50:39 pluto[9356] Warning: empty directory
14:50:39 pluto[9356] Changing to directory '/etc/ipsec.d/crls'
14:50:39 pluto[9356] Warning: empty directory
14:50:39 ipsec_setup ...Openswan IPsec started
14:50:39 pluto[9356] Changing to directory '/etc/ipsec.d/cacerts'
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_SSH_PRIVATE_65289: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_TWOFISH_CBC: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_hash(): Activating OAKLEY_SHA2_512: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_hash(): Activating OAKLEY_SHA2_256: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_SERPENT_CBC: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_CAST_CBC: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_BLOWFISH_CBC: Ok (ret=0)
14:50:39 pluto[9356] ike_alg_register_enc(): Activating OAKLEY_AES_CBC: Ok (ret=0)
14:50:39 pluto[9356] including NAT-Traversal patch (Version 0.6)
14:50:39 pluto[9356] including X.509 patch with traffic selectors (Version 0.9.42)
14:50:39 pluto[9356] Starting Pluto (Openswan Version 1.0.10)
14:50:39 ipsec__plutorun Starting Pluto subsystem...
14:50:39 ipsec_setup KLIPS ipsec0 on eth0 192.168.16.114/255.255.255.0 broadcast 192.168.16.255
14:50:39 ipsec_setup KLIPS debug `none'
14:50:39 ipsec_setup Starting Openswan IPsec 1.0.10...
14:50:38 ipsec_setup ...Openswan IPsec stopped
14:50:38 ipsec_setup ipsec: Device or resource busy
14:50:38 ipsec_setup /usr/lib/ipsec/tncfg: Socket ioctl failed on detach -- No such device. Is the v irtual device valid? The ipsec module may not be linked into the kernel or load ed as a module.
14:50:37 pluto[9075] shutting down interface ipsec0/eth0 192.168.16.114
14:50:37 pluto[9075] shutting down interface ipsec0/eth0 192.168.16.114
14:50:37 pluto[9075] "test": deleting connection
14:50:37 pluto[9075] forgetting secrets
14:50:37 pluto[9075] shutting down
14:50:37 ipsec_setup Stopping Openswan IPsec...
je met à la suite les logs de la machine B (attention il sont dans l'ordre inverse)
15:16:22 ipsec_setup Stopping Openswan IPsec...
15:16:22 pluto[2985] shutting down
15:16:22 pluto[2985] forgetting secrets
15:16:22 pluto[2985] "Mairie": deleting connection
15:16:22 pluto[2985] shutting down interface ipsec0/eth1 192.168.0.150
15:16:22 pluto[2985] shutting down interface ipsec0/eth1 192.168.0.150
15:16:23 ipsec_setup ipsec: Device or resource busy
15:16:23 ipsec_setup ...Openswan IPsec stopped
15:16:32 ipsec_setup Stopping Openswan IPsec...
15:16:32 ipsec_setup stop ordered, but IPsec does not appear to be running!
15:16:32 ipsec_setup doing cleanup anyway...
15:16:32 ipsec_setup ipsec: Device or resource busy
15:16:32 ipsec_setup ...Openswan IPsec stopped
15:16:32 ipsec_setup Starting Openswan IPsec 1.0.10...
15:16:32 ipsec_setup KLIPS debug `none'
15:16:32 ipsec_setup KLIPS ipsec0 on eth1 192.168.0.150/255.255.255.0 broadcast 192.168.0.255
15:16:32 ipsec__plutorun Starting Pluto subsystem...
15:16:32 pluto[3802] Starting Pluto (Openswan Version 1.0.10)
15:16:32 pluto[3802] including X.509 patch with traffic selectors (Version 0.9.42)
15:16:32 pluto[3802] including NAT-Traversal patch (Version 0.6)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_AES_CBC: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_BLOWFISH_CBC: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_CAST_CBC: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_SERPENT_CBC: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_hash(): Activating OAKLEY_SHA2_256: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_hash(): Activating OAKLEY_SHA2_512: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_TWOFISH_CBC: Ok (ret=0)
15:16:32 pluto[3802] ike_alg_register_enc(): Activating OAKLEY_SSH_PRIVATE_65289: Ok (ret=0)
15:16:32 pluto[3802] Changing to directory '/etc/ipsec.d/cacerts'
15:16:32 ipsec_setup ...Openswan IPsec started
15:16:32 pluto[3802] Warning: empty directory
15:16:32 pluto[3802] Changing to directory '/etc/ipsec.d/crls'
15:16:32 pluto[3802] Warning: empty directory
15:16:32 pluto[3802] OpenPGP certificate file '/etc/pgpcert.pgp' not found
15:16:32 pluto[3802] | from whack: got --esp=aes128-sha1,aes128-md5,3des-sha1,3des-md5
15:16:32 pluto[3802] | from whack: got --ike=aes128-sha-modp1536,aes128-sha-modp1024,aes128-md5-modp1 536,aes128-md5-modp1024,3des-sha-modp1536,3des-sha-modp1024,3des-md5-modp1536,3d es-md5-modp1024
15:16:32 pluto[3802] added connection description "Mairie"
15:16:32 pluto[3802] listening for IKE messages
15:16:32 pluto[3802] adding interface ipsec0/eth1 192.168.0.150
15:16:32 pluto[3802] adding interface ipsec0/eth1 192.168.0.150:4500
15:16:32 pluto[3802] loading secrets from "/etc/ipsec.secrets"
15:16:32 ipsec__plutorun 022 "Mairie": we have no ipsecN interface for either end of this connection
15:16:32 ipsec__plutorun ...could not route conn "Mairie"
15:16:32 pluto[3802] "Mairie": we have no ipsecN interface for either end of this connection
15:16:32 ipsec__plutorun 022 "Mairie": we have no ipsecN interface for either end of this connection
15:16:32 ipsec__plutorun ...could not start conn "Mairie"
Dans les logs de la machine B, nous n'avons pas d'erreur du type :
ipsec_setup /usr/lib/ipsec/tncfg: Socket ioctl failed on detach -- No such device. Is the v irtual device valid? The ipsec module may not be linked into the kernel or load ed as a module.
Je pense que c'est parce que la machine place l'interface ipsec0 sur RED, a l'inverse de la machine A qui le place sur GREEN
J'espere avoir été assez clair ...