Diff for /wikisrc/tutorials/how_to_stop_x11_from_listening_on_port_6000.mdwn between versions 1.1 and 1.2

version 1.1, 2011/11/20 20:55:21 version 1.2, 2012/02/05 07:14:36
Line 1 Line 1
 By default, the X server listens on port 6000 for incoming connections. If you are directly connected to the internet, or don't trust others connected to your LAN, this could be a potential security risk.  By default, the X server listens on port 6000 for incoming connections. If you are directly connected to the internet, or don't trust others connected to your LAN, this could be a potential security risk. 
   
 Disabling this can accomplished one of two ways. The first possible way is to run startx with the -nolisten tcp flag, i.e.  Disabling this can accomplished one of two ways. The first possible way is to run startx with the -nolisten tcp flag, i.e. 
          
     startx -- -nolisten tcp      startx -- -nolisten tcp
          
   
 The more permanent way to do it (globally) is to edit the startx script. It will be located at /usr/X11R6/bin/startx if you installed the base X11, or /usr/pkg/xorg/bin/startx if you installed X.org from pkgsrc.  The more permanent way to do it (globally) is to edit the startx script. It will be located at /usr/X11R6/bin/startx if you installed the base X11, or /usr/pkg/xorg/bin/startx if you installed X.org from pkgsrc. 
   
 Change the serverargs line to look like this:  Change the serverargs line to look like this: 
          
     serverargs="-nolisten tcp"      serverargs="-nolisten tcp"
          
   
 If you are not the administrator of the system or you like to let free the users to choose their configuration, edit (or create) the ~/.xserverrc file and put this line to it:  If you are not the administrator of the system or you like to let free the users to choose their configuration, edit (or create) the ~/.xserverrc file and put this line to it: 
          
     exec X -nolisten tcp      exec X -nolisten tcp
          
   
      
 Restart X, and you're all set!  Restart X, and you're all set! 
   
   

Removed from v.1.1  
changed lines
  Added in v.1.2


CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb