Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Info |  Source |  Call Graph |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Local Variables  | All
Print Page as PDF
Routine: PSNOSKEY

Package: National Drug File

Routine: PSNOSKEY


Information

PSNOSKEY ;BIR/SJA-PPS-N SSH Key Management ;09/16/2016

Source Information

Source file <PSNOSKEY.m>

Call Graph

Call Graph

Call Graph Total: 12

Package Total Call Graph
Kernel 8 ($$FTG,CLOSE,DEL,OPEN)^%ZISH  USE^%ZISUTL  ($$OS,$$VERSION)^%ZOSV  ^%ZTLOAD  ($$FMTHL7,$$HTFM,$$NOW)^XLFDT  $$LOW^XLFSTR  SIG^XUSESIG  ($$DECRYP,$$ENCRYP)^XUSRB1  
VA FileMan 3 (,UPDATE)^DIE  $$GET1^DIQ  ^DIR  
National Drug File 1 ($$DIREXIST,MAKEDIR)^PSNFTP2  

Caller Graph

Legends:

Legend of Colors

Package Component Superscript legend

action A extended action Ea event driver Ed subscriber Su protocol O limited protocol LP run routine RR broker B edit E server Se print P screenman SM inquire I

Caller Graph

Caller Graph Total: 2

Package Total Caller Graph
Kernel 1 ^DIC(19  
National Drug File 1 PSN PPS SSH KEY MANAGEMENT  

Entry Points

Name Comments DBIA/ICR reference
EN ; -- Entry point
ACTION ; -- SSH Key Action
END ;
NEWKEY(ENCRTYPE) ; Generate and store a pair of SSH keys
; Input: (o) ENCRTYPE - SSH Encryption Type (DSA/RSA) (Default: RSA)
RETRIEVE(KTYPE) ; Retrieve the SSH Key into the ^TMP global
; (o) KTYPE - SSH Key Type (PUB - Public/PRV - PRivate) (Default: Public)
VIEW ; Displays the SSH Public Key
; ^TMP("PSNPUBKY",$J,0)="SSH Key Format (SSH2/OpenSSH)^Encryption Type (DSA/RSA)"
; ^TMP("PSNPUBKY",$J,1-N)=[SSH Key Content]
DELETE ; Delete Both SSH Keys associated
OPENSSH() ; Returns the SSH Public Key in OpenSSH Format (Converts if necessary)
ENDOS() ; Returns the Backend Server Operating System (OS)
SETOS(JOB) ; Sets the Operating Systems in ^XTMP("PSNKEY",$J,"OS") (Called via Taskman)
HELP ; Encryption Type Help
HELP1 ; Encryption Type Help
PAUSE ; Pauses screen until user hits Return
ASK() ; confirm creating new pair

External References

Name Field # of Occurrence
$$FTG^%ZISH NEWKEY+40, NEWKEY+43
CLOSE^%ZISH NEWKEY+21
DEL^%ZISH NEWKEY+47
OPEN^%ZISH NEWKEY+17
USE^%ZISUTL NEWKEY+18
$$OS^%ZOSV NEWKEY+4, ENDOS+10, SETOS+2
$$VERSION^%ZOSV NEWKEY+30, NEWKEY+33
^%ZTLOAD ENDOS+7
^DIE NEWKEY+66, DELETE+2
UPDATE^DIE NEWKEY+61
$$GET1^DIQ ACTION+19, ACTION+25, NEWKEY+5, RETRIEVE+7, RETRIEVE+12
^DIR ACTION+3, ACTION+28, ACTION+34, ACTION+39, ACTION+63, PAUSE+1, ASK+4
$$DIREXIST^PSNFTP2 NEWKEY+27
MAKEDIR^PSNFTP2 NEWKEY+27
$$FMTHL7^XLFDT NEWKEY+10
$$HTFM^XLFDT NEWKEY+10
$$NOW^XLFDT ENDOS+7
$$LOW^XLFSTR NEWKEY+20, NEWKEY+29, NEWKEY+32
SIG^XUSESIG ACTION+10
$$DECRYP^XUSRB1 RETRIEVE+10
$$ENCRYP^XUSRB1 NEWKEY+58, NEWKEY+59

Interaction Calls

Name Line Occurrences
Function Call: WRITE
  • Prompt: !
  • Line Location: ACTION+13
Function Call: WRITE
  • Prompt: !!,"No action taken!",$C(7)
  • Line Location: ACTION+17
Function Call: WRITE
  • Prompt: "Done",$C(7)
  • Line Location: ACTION+55
Function Call: WRITE
  • Prompt: !!,"[No SSH Key Pair found]",$C(7)
  • Line Location: ACTION+60
Function Call: WRITE
  • Prompt: "Done",$C(7)
  • Line Location: ACTION+64
Function Call: WRITE
  • Prompt: !,"Public SSH Key (",$P($G(^TMP("PSNPUBKY",$J,0)),"^",2),") content (does not include dash lines):"
  • Line Location: VIEW+5
Function Call: WRITE
  • Prompt: !,DASHLN
  • Line Location: VIEW+6
Function Call: WRITE
  • Prompt: !,$E(SSHKEY,1,80)
  • Line Location: VIEW+7
Function Call: WRITE
  • Prompt: !,DASHLN
  • Line Location: VIEW+8
Function Call: WRITE
  • Prompt: !!,"Secure SHell (SSH) Encryption Keys are used to allow data file download."
  • Line Location: HELP+1
Function Call: WRITE
  • Prompt: !,"Follow the steps below to successfully setup data file download from Austin "
  • Line Location: HELP+2
Function Call: WRITE
  • Prompt: !,"server to VistA sites:",!
  • Line Location: HELP+3
Function Call: WRITE
  • Prompt: !,"Step 1: Select the 'C' (Create New SSH Key Pair) Action and follow the prompts"
  • Line Location: HELP+4
Function Call: WRITE
  • Prompt: !," to create a new pair of SSH keys. If you already have an existing SSH"
  • Line Location: HELP+5
Function Call: WRITE
  • Prompt: !," Key Pair you can skip this step."
  • Line Location: HELP+6
Function Call: WRITE
  • Prompt: !," You can check whether you already have an existing SSH Key Pair"
  • Line Location: HELP+7
Function Call: WRITE
  • Prompt: !," through the 'V' (View Public SSH Key) Action."
  • Line Location: HELP+8
Function Call: WRITE
  • Prompt: !,""
  • Line Location: HELP+9
Function Call: WRITE
  • Prompt: !!,"Step 2: Share the Public SSH Key content with the PPS-N SFTP server (Austin)."
  • Line Location: HELP+11
Function Call: WRITE
  • Prompt: !," In order to successfully establish the data download files, the SFTP "
  • Line Location: HELP+12
Function Call: WRITE
  • Prompt: !," server at Austin needs to install/configure the new SSH Key created in"
  • Line Location: HELP+13
Function Call: WRITE
  • Prompt: !," step 1 for the user id they assigned to your site. Use the 'V' (View "
  • Line Location: HELP+14
Function Call: WRITE
  • Prompt: !," Public SSH Key) Action to retrieve the content of the Public SSH key."
  • Line Location: HELP+15
Function Call: WRITE
  • Prompt: !," The Public SSH Key should not contain line-feed characters, therefore "
  • Line Location: HELP+16
Function Call: WRITE
  • Prompt: !," after you copy & paste it from the terminal emulator into an email or "
  • Line Location: HELP+17
Function Call: WRITE
  • Prompt: !," text editor make sure it contains only one line of text (no wrapping)."
  • Line Location: HELP+18
Function Call: WRITE
  • Prompt: !," Encryption Type: RSA or ECDSA?"
  • Line Location: HELP1+1
Function Call: WRITE
  • Prompt: !," -----------------------------------"
  • Line Location: HELP1+2
Function Call: WRITE
  • Prompt: !," Rivest, Shamir & Adleman (RSA) has been one of the most common"
  • Line Location: HELP1+3
Function Call: WRITE
  • Prompt: !," encryption algorithms used by the IT industry for securely sharing data."
  • Line Location: HELP1+4
Function Call: WRITE
  • Prompt: !,""
  • Line Location: HELP1+5
Function Call: WRITE
  • Prompt: !," Elliptic Curve Digital Signature Algorithm (ECDSA) is a more complex"
  • Line Location: HELP1+6
Function Call: WRITE
  • Prompt: !," public key cryptography encryption algorithm that is now supported by"
  • Line Location: HELP1+7
Function Call: WRITE
  • Prompt: !," the VA. If ECDSA is selected you will be prompted to enter the Bit size."
  • Line Location: HELP1+8
Function Call: WRITE
  • Prompt: !," Valid selections are 256, 384 or 521."
  • Line Location: HELP1+9
Function Call: WRITE
  • Prompt: !,""
  • Line Location: HELP1+10
Function Call: WRITE
  • Prompt: !," You will need to contact the Austin SFTP server support to determine"
  • Line Location: HELP1+11
Function Call: WRITE
  • Prompt: !," which type to select."
  • Line Location: HELP1+12
Function Call: WRITE
  • Prompt: !
  • Line Location: PAUSE+1
Function Call: WRITE
  • Prompt: !!
  • Line Location: ASK+3
Routine Call
  • DIE
  • Line Location:
    • NEWKEY+66
    • DELETE+2
Routine Call
  • DIE
  • Line Location:
    • NEWKEY+61
Routine Call
  • DIR
  • Line Location:
    • ACTION+3
    • ACTION+28
    • ACTION+34
    • ACTION+39
    • ACTION+63
    • PAUSE+1
    • ASK+4

FileMan Files Accessed Via FileMan Db Call

FileNo Call Tags
^PS(57.23 - [#57.23] Classic Fileman Calls,  GET1^DIQ

Global Variables Directly Accessed

Name Line Occurrences  (* Changed,  ! Killed)
^TMP( NEWKEY+52, NEWKEY+55, NEWKEY+56, NEWKEY+57, NEWKEY+58, NEWKEY+62!, RETRIEVE+9!, RETRIEVE+10*, RETRIEVE+11, RETRIEVE+12*
^TMP("PSNPRVKY" NEWKEY+38!, NEWKEY+40, NEWKEY+41, DELETE+3!
^TMP("PSNPUBKY" ACTION+7!, ACTION+8, ACTION+36, ACTION+42, ACTION+52, ACTION+60, NEWKEY+38!, NEWKEY+43, NEWKEY+44, VIEW+5
DELETE+3!, OPENSSH+6, OPENSSH+7, OPENSSH+8, OPENSSH+9, OPENSSH+10, OPENSSH+13, OPENSSH+14, ASK+1
^XTMP("PSNKEY" ENDOS+4!, ENDOS+8, ENDOS+9!, SETOS+2*
^XUSEC("PSN PPS COORD" ACTION+5

Label References

Name Line Occurrences
$$ASK ACTION+17
$$ENDOS ACTION+18
$$OPENSSH VIEW+4
ACTION ACTION+5, ACTION+8, ACTION+10, ACTION+13, ACTION+16, ACTION+58, ACTION+66, ACTION+67
DELETE ACTION+42, ACTION+64, NEWKEY+12
END ACTION+4
HELP ACTION+66
HELP1 HELP+10
NEWKEY ACTION+51
PAUSE ACTION+9, ACTION+13, ACTION+22, ACTION+54, HELP+10
RETRIEVE ACTION+7, ACTION+51, ACTION+59
VIEW ACTION+13

Local Variables

Legend:

>> Not killed explicitly
* Changed
! Killed
~ Newed

Name Field # of Occurrence
COMFILE NEWKEY+16~*, NEWKEY+17, NEWKEY+22, NEWKEY+23
DA NEWKEY+3~, NEWKEY+65*, DELETE+1~, DELETE+2*
DASHLN VIEW+3~, VIEW+4*, VIEW+6, VIEW+8
DIE NEWKEY+3~, NEWKEY+65!*, DELETE+1~, DELETE+2*
DIR EN+1~, ACTION+1!, ACTION+23!, ACTION+32!, ACTION+38!, ACTION+62!, PAUSE+1!, ASK+2!
DIR("?" ACTION+23*, ACTION+32*, ASK+2*
DIR("A" ACTION+1*, ACTION+23*, ACTION+32*, ACTION+38*, ACTION+62*, PAUSE+1*, ASK+3*
DIR("B" ACTION+2*, ACTION+28*, ACTION+34*, ACTION+38*, ACTION+62*, ASK+4*
DIR(0 ACTION+2*, ACTION+26*, ACTION+27*, ACTION+33*, ACTION+38*, ACTION+62*, PAUSE+1*, ASK+2*
DIRUT ACTION+4, ACTION+28, ACTION+31, ACTION+39, ACTION+63, ASK+2!
DR NEWKEY+3~, NEWKEY+66*, DELETE+1~, DELETE+2*
DTE NEWKEY+3~, NEWKEY+10*, NEWKEY+16
DUOUT ACTION+4, ACTION+28, ACTION+31, ACTION+39, ACTION+63, ASK+2!
DUZ ACTION+5
ENCRBITS EN+1~, ACTION+35*, NEWKEY+28*, NEWKEY+31*, NEWKEY+32, NEWKEY+34, NEWKEY+35
ENCRTYPE ACTION+29*, ACTION+31, ACTION+35, ACTION+51, NEWKEY~, NEWKEY+8*, NEWKEY+20, NEWKEY+29*, NEWKEY+32, NEWKEY+34
, NEWKEY+35, NEWKEY+66, OPENSSH+4~, OPENSSH+7*, OPENSSH+11
ENDOS ENDOS+3~, ENDOS+5*, ENDOS+8*, ENDOS+10
FILE2DEL NEWKEY+3~
FILE2DEL( NEWKEY+23*, NEWKEY+36*
I ENDOS+3~, ENDOS+8*
>> IOBOFF ACTION+37, ACTION+61
>> IOBON ACTION+37, ACTION+61
JOB SETOS~, SETOS+2
KEYFILE NEWKEY+3~, NEWKEY+10*, NEWKEY+20, NEWKEY+23, NEWKEY+32, NEWKEY+34, NEWKEY+35, NEWKEY+36, NEWKEY+40, NEWKEY+43
, NEWKEY+67
KTYPE RETRIEVE~, RETRIEVE+6*, RETRIEVE+7, RETRIEVE+8
KYTXT NEWKEY+3~, NEWKEY+51!, RETRIEVE+5~
KYTXT( NEWKEY+58*, RETRIEVE+10
KYTXT(1 NEWKEY+55*, NEWKEY+57*, NEWKEY+59*
LN NEWKEY+3~, NEWKEY+52*, NEWKEY+55, NEWKEY+56, NEWKEY+57, NEWKEY+58, RETRIEVE+5~, RETRIEVE+10*, OPENSSH+4~, OPENSSH+8*
, OPENSSH+9, OPENSSH+10, OPENSSH+13*, OPENSSH+14
LOCALDIR EN+1~, ACTION+19*, ACTION+20, NEWKEY+3~, NEWKEY+5*, NEWKEY+17, NEWKEY+20, NEWKEY+22, NEWKEY+27, NEWKEY+32
, NEWKEY+34, NEWKEY+35, NEWKEY+40, NEWKEY+43, NEWKEY+47
OPENSSH OPENSSH+4~, OPENSSH+5*, OPENSSH+7*, OPENSSH+10*, OPENSSH+11*, OPENSSH+14*, OPENSSH+15
OVFLN NEWKEY+3~, NEWKEY+56*, NEWKEY+57
PSNDSA EN+1~, ACTION+25*, ACTION+26, ACTION+27
PSNOS EN+1~, ACTION+18*, ACTION+19, ACTION+21, NEWKEY+3~, NEWKEY+4*, NEWKEY+5, NEWKEY+15, NEWKEY+26, NEWKEY+40
, NEWKEY+43, NEWKEY+54, NEWKEY+59, NEWKEY+66
PSNSPC NEWKEY+3~, NEWKEY+50*, NEWKEY+52, NEWKEY+54, NEWKEY+55, NEWKEY+56, NEWKEY+57, NEWKEY+58, NEWKEY+59, NEWKEY+60
, NEWKEY+62, RETRIEVE+5~, RETRIEVE+8*, RETRIEVE+9, RETRIEVE+10, RETRIEVE+11, RETRIEVE+12
PV NEWKEY+3~, NEWKEY+34*, NEWKEY+35*
SAVEKEY NEWKEY+3~, NEWKEY+51!
SAVEKEY( NEWKEY+60*
SSHKEY VIEW+3~, VIEW+4*, VIEW+7*
X EN+1~, ACTION+10, NEWKEY+40*, NEWKEY+43*, RETRIEVE+5~, RETRIEVE+7*, ASK+2!
X1 EN+1~, ACTION+10
Y EN+1~, ACTION+5, ACTION+8, ACTION+10, ACTION+13, ACTION+16, ACTION+29, ACTION+35, ACTION+39, ACTION+58
ACTION+63, ACTION+66, ASK+1~*, ASK+2!, ASK+5
ZTDESC ENDOS+3~, ENDOS+6*
ZTDTH ENDOS+3~, ENDOS+7*
ZTIO ENDOS+3~, ENDOS+5*
ZTRTN ENDOS+3~, ENDOS+5*
ZTSK ENDOS+3~
Info |  Source |  Call Graph |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Local Variables  | All