Partage
  • Partager sur Facebook
  • Partager sur Twitter

Squid - Accès depuis le boulot

Sujet résolu
    9 septembre 2015 à 19:36:07

    Salut !

    Je voudrai me faire un serveur proxy perso pour l'utiliser au boulot et contourné les restrictions (rien de bien méchant des sites qui font passé le temps comme Hordes.fr).
    Du coup j'ai ressortie ma Raspberry b+ et j'y ai installé Squid et je l'ai paramétré rapidement.

    La config :

    http_port 3128
    #We recommend you to use the following two lines.
    acl QUERY urlpath_regex cgi-bin \?
    no_cache deny QUERY
    cache_mem 8 MBM
    
    maximum_object_size_in_memory 8 KB
    
    cache_dir ufs /var/spool/squid 100 16 256
    
    cache_access_log /var/log/squid/access.log
    cache_log /var/log/squid/cache.log
    cache_store_log /var/log/squid/store.log
    
    # Put your FQDN here
    visible_hostname freeduc-sup.foo.org
    
    pid_filename /var/run/squid.pid
    
    #Recommended minimum configuration:
    acl all src 0.0.0.0/0.0.0.0
    acl manager proto cache_object
    acl localhost src 127.0.0.1/255.255.255.255
    
    #Recommended minimum configuration:
    http_access allow manager localhost
    http_access allow all

    et pour voir j'ai fait un netstat mais étrange Squid n’apparait pas...

    root@raspberry-pi:~# /etc/init.d/squid start
    [ ok ] Starting Squid HTTP proxy: squid.
    root@raspberry-pi:~# netstat -ntpul
    Active Internet connections (only servers)
    Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
    tcp        0      0 127.0.0.1:6502          0.0.0.0:*               LISTEN      1757/murmurd
    tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      1903/sshd
    tcp6       0      0 :::64738                :::*                    LISTEN      1757/murmurd
    tcp6       0      0 :::22                   :::*                    LISTEN      1903/sshd
    udp        0      0 0.0.0.0:3259            0.0.0.0:*                           1839/dhclient
    udp        0      0 0.0.0.0:5353            0.0.0.0:*                           1661/avahi-daemon:
    udp        0      0 0.0.0.0:50414           0.0.0.0:*                           1661/avahi-daemon:
    udp        0      0 0.0.0.0:68              0.0.0.0:*                           1839/dhclient
    udp        0      0 192.168.1.10:123        0.0.0.0:*                           1722/ntpd
    udp        0      0 127.0.0.1:123           0.0.0.0:*                           1722/ntpd
    udp        0      0 0.0.0.0:123             0.0.0.0:*                           1722/ntpd
    udp6       0      0 :::21127                :::*                                1839/dhclient
    udp6       0      0 :::59345                :::*                                1661/avahi-daemon:
    udp6       0      0 :::64738                :::*                                1757/murmurd
    udp6       0      0 :::5353                 :::*                                1661/avahi-daemon:
    udp6       0      0 fe80::ba27:ebff:fe6:123 :::*                                1722/ntpd
    udp6       0      0 ::1:123                 :::*                                1722/ntpd
    udp6       0      0 :::123                  :::*                                1722/ntpd

    Il semblerai que squid s’arrête juste après le lancement???

    root@raspberry-pi:~# /etc/init.d/squid start
    [ ok ] Starting Squid HTTP proxy: squid.
    root@raspberry-pi:~# ps -e | grep squid
     2375 ?        00:00:00 squid
    root@raspberry-pi:~# netstat -ntpul
    Active Internet connections (only servers)
    Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
    tcp        0      0 127.0.0.1:6502          0.0.0.0:*               LISTEN      1757/murmurd
    tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      1903/sshd
    tcp6       0      0 :::64738                :::*                    LISTEN      1757/murmurd
    tcp6       0      0 :::22                   :::*                    LISTEN      1903/sshd
    udp        0      0 0.0.0.0:3259            0.0.0.0:*                           1839/dhclient
    udp        0      0 0.0.0.0:5353            0.0.0.0:*                           1661/avahi-daemon:
    udp        0      0 0.0.0.0:50414           0.0.0.0:*                           1661/avahi-daemon:
    udp        0      0 0.0.0.0:68              0.0.0.0:*                           1839/dhclient
    udp        0      0 192.168.1.10:123        0.0.0.0:*                           1722/ntpd
    udp        0      0 127.0.0.1:123           0.0.0.0:*                           1722/ntpd
    udp        0      0 0.0.0.0:123             0.0.0.0:*                           1722/ntpd
    udp6       0      0 :::21127                :::*                                1839/dhclient
    udp6       0      0 :::59345                :::*                                1661/avahi-daemon:
    udp6       0      0 :::64738                :::*                                1757/murmurd
    udp6       0      0 :::5353                 :::*                                1661/avahi-daemon:
    udp6       0      0 fe80::ba27:ebff:fe6:123 :::*                                1722/ntpd
    udp6       0      0 ::1:123                 :::*                                1722/ntpd
    udp6       0      0 :::123                  :::*                                1722/ntpd
    root@raspberry-pi:~# ps -e | grep squid
    root@raspberry-pi:~#

    Merci d'avance pour vos lumière!



    • Partager sur Facebook
    • Partager sur Twitter
      10 septembre 2015 à 9:40:03

      Salut,

      As-tu regardé les logs ?

      • Partager sur Facebook
      • Partager sur Twitter
      System test engineer
        10 septembre 2015 à 13:01:07

        étrange j'ai delete les logs lancer ensuite suid pour voir les erreurs.... mais maintenant il marche et est accessible! tant mieux et désolé de vous avoir dérangé.

        une question subsiste. Le port par défaut de squid est bloqué au boulot. donc comment faire? trouver un port ouvert et faire passer squid par ce port?

        • Partager sur Facebook
        • Partager sur Twitter
          10 septembre 2015 à 15:36:54

          Changer le port dans la config de squid suffira (tu mets le port 80, c'est sur que ça sera pas bloqué)
          • Partager sur Facebook
          • Partager sur Twitter
          System test engineer

          Squid - Accès depuis le boulot

          × Après avoir cliqué sur "Répondre" vous serez invité à vous connecter pour que votre message soit publié.
          × Attention, ce sujet est très ancien. Le déterrer n'est pas forcément approprié. Nous te conseillons de créer un nouveau sujet pour poser ta question.
          • Editeur
          • Markdown