Nmap tn3270-screen NSE Script


This page contains detailed information about how to use the tn3270-screen NSE script. For list of all NSE scripts, visit the Nmap NSE Library.

Select:
Overview
Error Messages

Script Overview


Script source code: https://github.com/nmap/nmap/tree/master/scripts/tn3270-screen.nse
Script categories: safe, discovery
Target service / protocol: tn3270
Target network port(s): 23, 992
List of CVEs: -

Script Description


The tn3270-screen.nse script connects to a tn3270 'server' and returns the screen.

Hidden fields will be listed below the screen with (row, col) coordinates.

Tn3270-screen NSE Script Arguments


This is a full list of arguments supported by the tn3270-screen.nse script:

tn3270-screen.commands

A semi-colon separated list of commands you want to issue before printing the screen tn3270-screen.lu specify a logical unit you with to use, fails if can't connect tn3270-screen.disable_tn3270e disables TN3270 Enhanced mode

- - -
To use this script argument, add it to Nmap command line like in this example:

nmap --script=tn3270-screen --script-args tn3270-screen.commands=value <target>

Tn3270-screen NSE Script Example Usage


Here's an example of how to use the tn3270-screen.nse script:

nmap --script tn3270-info,tn3270_screen <host>

Tn3270-screen NSE Script Example Output


Here's a sample output from the tn3270-screen.nse script:

PORT     STATE  SERVICE         VERSION
23/tcp   open   tn3270          Telnet TN3270
| tn3270-screen:
|  screen:
|  Mainframe Operating System                              z/OS V1.6
|          FFFFF  AAA  N   N      DDDD  EEEEE      ZZZZZ H   H  III
|          F     A   A NN  N      D   D E             Z  H   H   I
|          FFFF  AAAAA N N N      D   D EEEE         Z   HHHHH   I
|          F     A   A N  NN      D   D E           Z    H   H   I
|          F     A   A N   N      DDDD  EEEEE      ZZZZZ H   H  III
|
|                         ZZZZZ      / OOOOO  SSSS
|                            Z      /  O   O S
|                           Z      /   O   O  SSS
|                          Z      /    O   O     S
|                         ZZZZZ  /     OOOOO SSSS
|
|                   Welcome to Fan DeZhi Mainframe System!
|
|                       Support: http://zos.efglobe.com
|          TSO      - Logon to TSO/ISPF        NETVIEW  - Netview System
|          CICS     - CICS System              NVAS     - Netview Access
|          IMS      - IMS System               AOF      - Netview Automation
|
| Enter your choice==>
| Hi! Enter one of above commands in red.
|
|_Your IP(10.10.10.375   :64199), SNA LU(        )       05/30/15 13:33:37

Tn3270-screen NSE Script Example XML Output


There is no sample XML output for this module. However, by providing the -oX <file> option, Nmap will produce a XML output and save it in the file.xml file.

Author


  • Philip Young aka Soldier of Fortran

References


See Also


Visit Nmap NSE Library for more scripts.

The tn3270-screen.nse script may fail with the following error messages. Check for the possible causes by using the code snippets highlighted below found in the script source code. This can often times help in identifying the root cause of the problem.

Could not initiate TN3270: %s


Here is a relevant code snippet related to the "Could not initiate TN3270: %s" error message:

80:	  if disable_tn3270e then
81:	      t:disable_tn3270e()
82:	  end
83:	  local status, err = t:initiate(host,port)
84:	  if not status then
85:	    stdnse.debug("Could not initiate TN3270: %s", err )
86:	    return
87:	  else
88:	    if commands then
89:	      local run = stdnse.strsplit(";%s*", commands)
90:	      for i = 1, #run do

Version


This page has been created based on Nmap version 7.92.

Go back to menu.