<?xml version="1.0" standalone="yes"?>
<cliplibrary>
  <clip>
    <clipname>smpt test</clipname>
    <cliptext>telnet [server] 25
EHLO test.com
MAIL FROM:Admin@test.com
RCPT TO: User@Domain.Com
DATA
Subject: test message
[Subject: test message]
RCPT TO:User@Site.Domain.Com notify=success,failure
QUIT</cliptext>
    <clipdescription>telnet [server] 25
EHLO test.com
MAIL FROM:Admin@test.com
RCPT TO: User@Domain.Com
DATA
Subject: test message
[Subject: test message]
RCPT TO:User@Site.Domain.Com notify=success,failure
QUIT</clipdescription>
  </clip>
  <clip>
    <clipname>nslookup</clipname>
    <cliptext>see help</cliptext>
    <clipdescription>nslookup is used to communicate with dns servers

Nslookup.exe can be run in two modes: interactive and noninteractive. Noninteractive mode is useful when only a single piece of data needs to be returned. The syntax for noninteractive mode is: 

   nslookup [-option] [hostname] [server]
				

To start Nslookup.exe in interactive mode, simply type "nslookup" at the command prompt: 

   C:\&gt; nslookup
   Default Server:  nameserver1.domain.com
   Address:  10.0.0.1
   &gt;
				

Typing "help" or "?" at the command prompt will generate a list of available commands. Anything typed at the command prompt that is not recognized as a valid command is assumed to be a host name and an attempt is made to resolve it using the default server. To interrupt interactive commands, press CTRL+C. To exit interactive mode and return to the command prompt, type exit at the command prompt. 

The following is the help output and contains the complete list of options: 

Commands:   (identifiers are shown in uppercase, [] means optional)

 NAME            - print info about the host/domain NAME using default 
                   server
 NAME1 NAME2     - as above, but use NAME2 as server
 help or ?       - print info on common commands
 set OPTION      - set an option

    all                 - print options, current server and host
    [no]debug           - print debugging information
    [no]d2              - print exhaustive debugging information
    [no]defname         - append domain name to each query
    [no]recurse         - ask for recursive answer to query
    [no]search          - use domain search list
    [no]vc              - always use a virtual circuit
    domain=NAME         - set default domain name to NAME
    srchlist=N1[/N2/.../N6] - set domain to N1 and search list to N1, N2, 
                          and so on
    root=NAME           - set root server to NAME
    retry=X             - set number of retries to X
    timeout=X           - set initial time-out interval to X seconds
    type=X              - set query type (for example, A, ANY, CNAME, MX, 
                          NS, PTR, SOA, SRV)
    querytype=X         - same as type
    class=X             - set query class (for example, IN (Internet), ANY)
    [no]msxfr           - use MS fast zone transfer
    ixfrver=X           - current version to use in IXFR transfer request

 server NAME     - set default server to NAME, using current default server
 lserver NAME    - set default server to NAME, using initial server
 finger [USER]   - finger the optional NAME at the current default host
 root            - set current default server to the root
 ls [opt] DOMAIN [&gt; FILE] - list addresses in DOMAIN (optional: output to 
                  FILE)

    -a          -  list canonical names and aliases
    -d          -  list all records
    -t TYPE     -  list records of the given type (for example, A, CNAME, 
                   MX, NS, PTR, and so on)

 view FILE       - sort an 'ls' output file and view it with pg
 exit            - exit the program
				

A number of different options can be set in Nslookup.exe by running the set command at the command prompt. A complete listing of these options is obtained by typing set all. See above, under the set command for a printout of the available options. 



Looking up Different Data Types
To look up different data types within the domain name space, use the set type or set q[uerytype] command at the command prompt. For example, to query for the mail exchanger data, type the following: 
   C:\&gt; nslookup
   Default Server:  ns1.domain.com
   Address:  10.0.0.1

   &gt; set q=mx
   &gt; mailhost
   Server:  ns1.domain.com
   Address:  10.0.0.1

   mailhost.domain.com     MX preference = 0, mail exchanger =
                           mailhost.domain.com
   mailhost.domain.com     internet address = 10.0.0.5
   &gt;
				

The first time a query is made for a remote name, the answer is authoritative, but subsequent queries are nonauthoritative. The first time a remote host is queried, the local DNS server contacts the DNS server that is authoritative for that domain. The local DNS server will then cache that information, so that subsequent queries are answered nonauthoritatively out of the local server's cache. 



Querying Directly from Another Name Server
To query another name server directly, use the server or lserver commands to switch to that name server. The lserver command uses the local server to get the address of the server to switch to, while the server command uses the current default server to get the address. 

Example: 
   C:\&gt; nslookup

   Default Server:  nameserver1.domain.com
   Address:  10.0.0.1

   &gt; server 10.0.0.2

   Default Server:  nameserver2.domain.com
   Address:  10.0.0.2
   &gt;
				
Using Nslookup.exe to Transfer Entire Zone
Nslookup can be used to transfer an entire zone by using the ls command. This is useful to see all the hosts within a remote domain. The syntax for the ls command is: 

   ls [- a | d | t type] domain [&gt; filename]
				

Using ls with no arguments will return a list of all address and name server data. The -a switch will return alias and canonical names, -d will return all data, and -t will filter by type. 

Example:

   &gt;ls domain.com
   [nameserver1.domain.com]
    nameserver1.domain.com.    NS     server = ns1.domain.com
    nameserver2.domain.com                 NS     server = ns2.domain.com
    nameserver1                            A      10.0.0.1
    nameserver2                            A      10.0.0.2

   &gt;
				

Zone transfers can be blocked at the DNS server so that only authorized addresses or networks can perform this function. The following error will be returned if zone security has been set: 
</clipdescription>
  </clip>
  <clip>
    <clipname>net send</clipname>
    <cliptext>net send [computer] [message]</cliptext>
    <clipdescription>net send [computer name or ip address] message</clipdescription>
  </clip>
  <clip>
    <clipname>net use - map drive</clipname>
    <cliptext>net use p: \\servername\sharename /persistent:yes</cliptext>
    <clipdescription>net use allows you to map a drive

Save the following text bellow to a .bat file and execute it
@echo off
net use p: \\servername\sharename /persistent:yes</clipdescription>
  </clip>
  <clip>
    <clipname>net stop - stop a windows service</clipname>
    <cliptext>net stop [NameofService]</cliptext>
    <clipdescription>net stop "[service name]"</clipdescription>
  </clip>
  <clip>
    <clipname>net start - start a service</clipname>
    <cliptext>net start [NameofService]</cliptext>
    <clipdescription>start service - start a service</clipdescription>
  </clip>
  <clip>
    <clipname>Email vbs</clipname>
    <cliptext>Dim objMail, strSenderEmail, strDestinationEmail, strEmailSubject, strEmailBodyMsg

strSenderEmail = "username@domain.com"
strDestinationEmail = "username@domain.com"
strEmailSubject = "Email Subject " &amp; Date()
strEmailBodyMsg = "This is the body of the Message " &amp; Date()

Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = strSenderEmail
objMail.To = strDestinationEmail
objMail.Subject = strEmailSubject
objMail.Body = strEmailBodyMsg
objMail.Send

'Set Objects and Variables to Nothing
set objMail = nothing
strSenderEmail = ""
strDestinationEmail = ""
strEmailSubject = ""
strEmailBodyMsg = ""</cliptext>
    <clipdescription>'Test SMTP service is working (CDONTS)

Dim objMail, strSenderEmail, strDestinationEmail, strEmailSubject, strEmailBodyMsg

strSenderEmail = "username@domain.com"
strDestinationEmail = "username@domain.com"
strEmailSubject = "Email Subject " &amp; Date()
strEmailBodyMsg = "This is the body of the Message " &amp; Date()

Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = strSenderEmail
objMail.To = strDestinationEmail
objMail.Subject = strEmailSubject
objMail.Body = strEmailBodyMsg
objMail.Send

'Set Objects and Variables to Nothing
set objMail = nothing
strSenderEmail = ""
strDestinationEmail = ""
strEmailSubject = ""
strEmailBodyMsg = ""

</clipdescription>
  </clip>
</cliplibrary>