XUSUDOPI ;SLC/JLA - Post Install for P787 ; SEP 3, 2025@7:30
;;8.0;KERNEL;**787**;Jul 10, 1995;Build 73
;Per VA Directive 6402, this routine should not be modified.
;
; ***** IMPORTANT NOTE *******************************************
; This routine requires access to the manager (%SYS) namespace and
; can only be run by a user with permissions to that namespace.
; ****************************************************************
;
;
; FileMan/ScreenMan API's
FMDIE D ^DIE Q
;
;
; Loads "xusudo.xml" into XU*8.0*787 transport global. Post-installation
; routine ^XUSODOPI will reconstruct the file for the installation of Cache
; classes into VistA to support SSL/TLS.
;
POST ;
N STATUS
S STATUS=$$SAVETLSNAME()
I 'STATUS D BMES^XPDUTL($P(STATUS,U,2))
Q
;
;
SAVETLSNAME() ;
NEW KSPFILE,KSPIEN,TLSFIELD,TLSNAME,MESSAGE,RTNVAL
NEW DIE,DA,DR,DIK
S KSPFILE=8989.3 ; File number of Kernel System Parameter file
S KSPIEN=1 ; Only one record
; Set the Global root of the Kernel System Parameter file
S KSPGLBROOT="^XTV("_KSPFILE_","
; Setup the DIE call
S DIE=KSPGLBROOT ; Global root of subfile
S TLSFIELD=667
S TLSNAME="tls_encrypt_server"
S DA=KSPIEN
S DR=""_TLSFIELD_"////"_TLSNAME
;W !,"DIE: ",DIE,", DA: ",DA,", DR: ",DR
L +^XTV(8989.3):5
I $T D
. D FMDIE
. L -^XTV(8989.3)
. S MESSAGE="DEFAULT TLS SERVER CONFIG. initialized to ""tls_encrypt_server"""
. D BMES^XPDUTL("KERNEL SYSTEM PARAMETERS updated")
. D MES^XPDUTL(" "_MESSAGE)
. S RTNVAL="1^"_MESSAGE
E D
. SET MESSAGE="Another user is editing KERNEL SYSTEM PARAMETERS"
. D BMES^XPDUTL(MESSAGE)
. S RTNVAL="0^"_MESSAGE
SVTLSNMDN ;
Q RTNVAL
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HXUSUDOPI 1707 printed Jul 11, 2026@02:09:59 Page 2
XUSUDOPI ;SLC/JLA - Post Install for P787 ; SEP 3, 2025@7:30
+1 ;;8.0;KERNEL;**787**;Jul 10, 1995;Build 73
+2 ;Per VA Directive 6402, this routine should not be modified.
+3 ;
+4 ; ***** IMPORTANT NOTE *******************************************
+5 ; This routine requires access to the manager (%SYS) namespace and
+6 ; can only be run by a user with permissions to that namespace.
+7 ; ****************************************************************
+8 ;
+9 ;
+10 ; FileMan/ScreenMan API's
FMDIE DO ^DIE
QUIT
+1 ;
+2 ;
+3 ; Loads "xusudo.xml" into XU*8.0*787 transport global. Post-installation
+4 ; routine ^XUSODOPI will reconstruct the file for the installation of Cache
+5 ; classes into VistA to support SSL/TLS.
+6 ;
POST ;
+1 NEW STATUS
+2 SET STATUS=$$SAVETLSNAME()
+3 IF 'STATUS
DO BMES^XPDUTL($PIECE(STATUS,U,2))
+4 QUIT
+5 ;
+6 ;
SAVETLSNAME() ;
+1 NEW KSPFILE,KSPIEN,TLSFIELD,TLSNAME,MESSAGE,RTNVAL
+2 NEW DIE,DA,DR,DIK
+3 ; File number of Kernel System Parameter file
SET KSPFILE=8989.3
+4 ; Only one record
SET KSPIEN=1
+5 ; Set the Global root of the Kernel System Parameter file
+6 SET KSPGLBROOT="^XTV("_KSPFILE_","
+7 ; Setup the DIE call
+8 ; Global root of subfile
SET DIE=KSPGLBROOT
+9 SET TLSFIELD=667
+10 SET TLSNAME="tls_encrypt_server"
+11 SET DA=KSPIEN
+12 SET DR=""_TLSFIELD_"////"_TLSNAME
+13 ;W !,"DIE: ",DIE,", DA: ",DA,", DR: ",DR
+14 LOCK +^XTV(8989.3):5
+15 IF $TEST
Begin DoDot:1
+16 DO FMDIE
+17 LOCK -^XTV(8989.3)
+18 SET MESSAGE="DEFAULT TLS SERVER CONFIG. initialized to ""tls_encrypt_server"""
+19 DO BMES^XPDUTL("KERNEL SYSTEM PARAMETERS updated")
+20 DO MES^XPDUTL(" "_MESSAGE)
+21 SET RTNVAL="1^"_MESSAGE
End DoDot:1
+22 IF '$TEST
Begin DoDot:1
+23 SET MESSAGE="Another user is editing KERNEL SYSTEM PARAMETERS"
+24 DO BMES^XPDUTL(MESSAGE)
+25 SET RTNVAL="0^"_MESSAGE
End DoDot:1
SVTLSNMDN ;
+1 QUIT RTNVAL