Notes for Computer Information Technology 160
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

oct22-dns2.md 1.1KB

October 22 - DNS Continued (and Ports)

Overview

  • Local Files
    • /etc/services
    • /etc/resolv.conf
    • /etc/nsswitch.conf
    • /etc/hosts
  • BIND, Domain
  • DNS Records
  • Zone Files

Unix filesystem standards

  • bin - binary executables
  • sbin - system administator’s binary executables
  • etc - configuration files
  • tmp - temporary files (wiped on boot up)
  • var - writable, non-sharable files

Local Files

  • /etc/resolve.conf lists the current dns server for resolving dns requests
  • /etc/hosts is a local list of dns entries
  • /etc/nsswitch.conf is the config of the GNU Name Service Switch
# /etc/hosts can be used to block websites:
$ echo '0.0.0.0 example.com' >> /etc/hosts

Ports

A socket contains a source and destination ip and port, it lists every connection.

Ports 0-1024 are “privilege ports” and require root to use.

Port 42 used to be used for WINS, Windows Internet Naming Service, before it was replaced with regular DNS.

Port 53 is for DNS.

HTTP is on port 80 for the server and for any port over 1024 for the client.