*# TMESIS.BCKz TMESIS.BCKPBACK/TRUNC/LOG/BLOCK=8192 DVA0:[*...] NORLMN"everhart password"::TMESIS.BCK/SAVE SYSTEM A:X691 _FALM25::  V6.2  *[000000]000000.DIR;1+,./ 4-0123 KPWO56g27g289GHJI 000000.DIR BACKUP.SYS BADBLK.SYS BADLOG.SYS  BITMAP.SYS CONTIN.SYS CORIMG.SYS DECUS.DIR  INDEXF.SYS SECURITY.SYS  VOLSET.SYS*[000000]DECUS.DIR;1+, ./ 4-0123 KPWO56@\27>ī289GHJI  AMIDBG.DIR CTRL-VERIFY.DIR DBG_SHELL.DIR GOTOUNWIND.DIR) PERMANENT.DIR. REPEAT.DIR5 SSINT.DIR: SYMBOL.DIRC*[DECUS]AMIDBG.DIR;1+, ./ 4- 0123 KPWO56`=27m@289GHJI $$$README.TXT  AMIDBG.MAR DESCRIP.MMS*[DECUS.AMIDBG]$$$README.TXT;1+, ./ 4O@- 0123KPWO56 F07F089GHJO.-----------------------------------------------------------------------------.O| Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED. |O| |O| This software is provided "AS IS" and is supplied for informational purpose |O| only. No warranty is expressed or implied and no liability can be accepted |O| for any actions or circumstances incurred from the use of this software or |O| from the information contained herein. The author makes no claim as to the |O| suitablility or fitness of the software or information contain herein for a |O| particular purpose. |O| |O| Permission is hereby granted _ONLY_ for the "not-for-profit" redistribution |O| of this software provided that ALL SOURCE and/or OBJECT CODE remains intact |O| and ALL COPYRIGHT NOTICES remain intact from its original distribution. |O| |O|(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!) |O`-----------------------------------------------------------------------------'Package name: AMIDBGGDescription: Demonstration of one method to determine if a debugger is mapped.$Author's name: Brian SchenkenbergerPackage Overview:----------------HThis program is a "quick and dirty" program hack to demonstrate a methodJto determine if and if so, which debugger is mapped in an activated image.--Build: (Both VAX and Alpha)  $ MACROO AMIDBG.MAR {/DEBUG} $ LINKK AMIDBG.OBJ {/DEBUG}F* Note: A DESCRIP.MMS file is provided to build the AMIDBG executable.-- .END. *[DECUS.AMIDBG]AMIDBG.MAR;1+,. / 4M - 0123KPWO 56.ؙ7 89GHJ 7 .TITLE AMIDBG ; demo to determine if running debugger; .IDENT /V1.0%6.038/ ; first version: V1.0%February 7, 1996 .PSECT $DATA$,WRT,EXE,5*NODBG: .ASCID /Sorry, no debugger mapped./1DBGFMT: .ASCID /Yes, the !AC debugger is mapped./9DBGOUT: .ASCID / / .PSECT $CODE$,NOWRT,EXE,5 .ENTRY GO,0 JSB AMIDBG BLBS R0, 10$ PUSHAB NODBG CALLS #1,G^LIB$PUT_OUTPUT RET;10$: $FAO_S CTRSTR=DBGFMT,OUTBUF=DBGOUT,OUTLEN=DBGOUT,P1=R1 PUSHAB DBGOUT CALLS #1,G^LIB$PUT_OUTPUT RET ;++A; Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedL; for any actions or circumstances incurred from the use of this software orM; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted _ONLY_ for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactI; and ALL COPYRIGHT NOTICES remain intact from its original distribution.;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--9; Author: Brian Schenkenberger ; Created: February 7, 1996;-- E; This routine will determine if the OpenVMS symbolic debugger or theF; DELTA debugger ara mapped in the address space of the current activeH; image. It is written so that it may be included anywhere in the code.;; Format: JSB AMIDBG;); Returns: R0 = 0 ; no debugger is mapped!; R0 =-1 ; a debugger is mapped ;7; R1 = address of .ASCIC string with the debugger name;-- .SAVE_PSECT LOCAL_BLOCK .PSECT $AMIDBG_DATA$,WRT,EXE,5;++I; The following determines the value of the image name cell offset in theI; image control block on either VAX or Alpha. The structure's prefix wasI; changed from ICB on the VAX to IMCB on the Alpha. I've employed one ofI; my favorite tricks to compute the cell offset independent of the targetI; architecture using the .WEAK Macro-32 directives. This circumvents theB; use of the "confidential & proprietary alpha porting technique".;--! .WEAK ICB$T_IMAGE_NAME ; on VAX$ .WEAK IMCB$T_IMAGE_NAME ; on Alpha .ALIGN QUAD1NAME: .ADDRESS ICB$T_IMAGE_NAME!IMCB$T_IMAGE_NAMEDEBUG: .ASCIC /DEB-3x TMESIS.BCK [DECUS.AMIDBG]AMIDBG.MAR;1M iUG/DEBUGSZ=.-DEBUG .ALIGN LONGDELTA: .ASCIC /DELTA/DELTASZ=.-DELTA ASSUME DEBUGSZ EQ DELTASZ .PSECT $AMIDBG_CODE$,WRT,EXE,5 .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^xF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGING!AMIDBG: .IIF DF,ALPHA, .JSB_ENTRY) CLRQ R0 ; assume no debugger is mapped< PUSHR #^M ; save routine trashed registers @ MOVAL G^IAC$GL_IMAGE_LIST,R4 ; get image control block listhead010$: MOVL (R4),R4 ; get an image control block6 CMPL R4,#IAC$GL_IMAGE_LIST ; is the list exhausted???0 BEQL 30$ ; yes, then it's the end of the line: CMPC3 #DEBUGSZ,DEBUG,@NAME[R4]; is this the DEBUG I(M)CB  BEQL 20$ ; yeap... : CMPC3 #DELTASZ,DELTA,@NAME[R4]; is this the DELTA I(M)CB ) BNEQ 10$ ; no? get another image block820$: MNEGL #1,(SP) ; signify that a debugger is mapped? MOVAB <-DEBUGSZ>(R1),4(SP) ; return address of debugger's nameB30$: POPR #^M ; restore routine trashed registers  RSB .RESTORE_PSECT .END GO*[DECUS.AMIDBG]DESCRIP.MMS;1+,./ 4B>- 0123KPWO56Z7h#Z89GHJB####################################################################-## Copyright (c) 1996 by Brian Schenkenberger## All Rights Reserved.##B################################################################## EXE = .EXE MAR = .MAR OBJ = .OBJMFLAGS = $(MFLAGS)/LIST!LINKFLAGS = $(LINKFLAGS)/MAP/FULL##3## AMIDBG is composed of the following image files:##AMIDBG : AMIDBG$(EXE)1 @ WRITE SYS$OUTPUT "AMIDBG Build is complete."AMIDBG$(EXE) : AMIDBG$(OBJ)) $(LINK)$(LINKFLAGS) $(MMS$SOURCE_LIST)AMIDBG$(OBJ) : AMIDBG$(MAR)*[DECUS]CTRL-VERIFY.DIR;1+,./ 4- 0123 KPWO56 27 289GHJI*$$$CTRL_VERIFY.INFO-V2-1_6-091($$$CTRL_VERIFY.INFO-V2_4-253 BUILD.COM CTRLV.CLD CTRLV.RNH CTRLVCMD.CLD DESCRIP.MMS"INSTALL_CTRLV.TEMPLATELOAD_CTRLV.MAR"STARTUP_CTRLV.TEMPLATEVAST_SHARE.AXP_OPTVAST_SHARE.MARVAST_SHARE.OPT_QT.COM _TEST.COM3*[DECUS.CTRL-VERIFY]$$$CTRL_VERIFY.INFO-V2-1_6-091;1+,. / 4K -0123KPWO 56!7#}>/89GHJCopyright 1994, 1996 by Brian Schenkenberger. All rights reserved. ------------------------- This software is provided "as is" and is supplied for informational purpose only. No warranty is expressed or implied and no liability can be accepted for any actions or circumstances incurred from the use of this software or from the information contained herein. The author makes no claim as to the suitability or fitness of this software or information contained herein for a particular purpose. ------------------------- This software may be copied and distributed only with the inclusion of this copyright notice. >-------------------------------------------------------------------------< *** CTRL-Verify (V2.1 6%091) *** Description: =========== CTRL-Verify provides the capability to enable and disable DCL command file verification by typing a CTRL-V while the procedure is executing. CTRL-Verify was initially created with the intention of demonstrating the mechanics for loading code into a process's P1 space on OpenVMS AlphaAXP. CTRL-Verify demonstrates how to load code into P1 space using a mechanism which provides a common code base on both OpenVMS platforms, AlphaAXP and VAX. >-------------------------------------------------------------------------< Release Information: =================== This is an update release of CTRL-Verify. (v2.1 6%091) This release was updated to add several code modifications to allow this package to be installed for use on OpenVMS Alpha and OpenVMS VAX version V7.0. Distribution Information: ======================== CTRL-Verify requires both CMEXEC and LOG_IO privilege and executes code in executive and kernel access modes. Therefore, CTRL-Verify is distributed in source form for inspection. This package contains the following files: ========================================= $$$CTRL-VERIFY.INFO .......... This file. Background/release information. $$$CTRL-VERIFY.INFO-V2_4-253 . V2.4%253 Background/release information. BUILD.COM .................... Compile and link the sources. DESCRIP.MMS .................. MMS (MMK) build rules. LOAD_CTRLV.MAR ............... The CTRL-Verify loader. VAST_SHARE.MAR ............... The verify AST routine. CTRLVCMD.CLD ................. The command definition file. VAST_SHARE.OPT ............... OpenVMS VAX linker option file VAST_SHARE.AXP_OPT ........... OpenVMS AXP linker option file CTRLV.CLD .................... Define CTRLV as a DCL command .CLD CTRLV.RNH .................... RUNOFF help file source INSTALL_CTRLV.TEMPLATE ....... Template procedure to install CTRL-Verify STARTUP_CTRLV.TEMPLATE ....... Template procedure to startup CTRL-Verify Installation Information: ======================== The logical VAST_SHARE must be defined to point to the location of the P1 AST routine shareable image, VAST_SHARE.EXE, prior to executing the loader image, LOAD_CTRLV.EXE. When the loader image, LOAD_CTRLV.EXE, is installed with the privileges CMEXEC and LOG_IO, the VAST_SHARE logical must be defined SYSTEM/EXEC. $ DEFINE/SYSTEM/EXEC VAST_SHARE {dev}:[{dir}]VAST_SHARE.EXE ----- The LOAD_CTRLV.EXE routine requires the privileges: CMEXEC and LOG_IO. LOAD_CTRLV.EXE may be installed with these privileges to permit a non- privileged user to load the CTRL-Verify AST. $ INSTALL ADD/PRIV=(CMEXEC,LOG_IO) {dev}:[{dir}]LOAD_CTRLV.EXE If the LOAD_CTRLV.EXE image is installed with privileges, VAST_SHARE.EXE must be installed as well. $ INSTALL ADD {dev}:[{dir}]VAST_SHARE.EXE ----- The VNff TMESIS.BCK3[DECUS.CTRL-VERIFY]$$$CTRL_VERIFY.INFO-V2-1_6-091;1K c5AST_SHARE.EXE image must be accessible to the process issuing the load. If CTRL-Verify is to be executed by all processes on the system, VAST_SHARE.EXE it should have WORLD:READ,EXECUTE file protection. ----- To use CTRL-Verify, define the foreign command CTRLV for executing the LOAD_CTRLV.EXE image. $ CTRLV:==$device:[directory]LOAD_CTRLV.EXE Note: The file CTRLV.CLD is supplied if you wish to add CTRLV to your DCL command tables. If you opt to add CTRLV to your command tables, you will need to define the system logical LOAD_CTRLV to point to the location of the LOAD_CTRLV.EXE image. ----- The CTRL-Verify AST may be loaded with the command: $ CTRLV/KEY= See the CTRLV.HLP file for the keywords. -------------------------------------------------------------------------- Any feedback on CTRL-Verify will be greatly appreciated. Send comments or suggestions to: or . -------------------------------------------------------------------------- .END. 1*[DECUS.CTRL-VERIFY]$$$CTRL_VERIFY.INFO-V2_4-253;1+,. / 4K -0123KPWO 56u7u89GHJCopyright 1994 by Brian Schenkenberger. All rights reserved. ------------------------- This software is provided "as is" and is supplied for informational purpose only. No warranty is expressed or implied and no liability can be accepted for any actions or circumstances incurred from the use of this software or from the information contained herein. The author makes no claim as to the suitability or fitness of this software or information contained herein for a particular purpose. ------------------------- This software may be copied and distributed only with the inclusion of this copyright notice. >-------------------------------------------------------------------------< *** CTRL-Verify (V2) *** Description: =========== CTRL-Verify provides the capability to enable and disable DCL command file verification by typing a CTRL-V while the procedure is executing. CTRL-Verify was initially created with the intention of demonstrating the mechanics for loading code into a process's P1 space on OpenVMS AlphaAXP. CTRL-Verify demonstrates how to load code into P1 space using a mechanism which provides a common code base on both OpenVMS platforms, AlphaAXP and VAX. >-------------------------------------------------------------------------< Release Information: =================== This is an update release of CTRL-Verify. (v2.4%253) This release was updated to add several code modifications to allow this package to be installed for use as an actual system utility. Originally, this package was intended *only* as a demonstration for loading P1 space, however, a number of sites were using CTRL-Verify wholey for its ability to toggle the DCL verify bit. This release supports installing the load routine with privileges. The installation information has been modified to detail additional installation requirements. These changes are due to the image activator's security counter-measures which will be 'in force' when the image is installed and are do to the ramifications of installing a routine with privileges. In addition, the LOAD_CTRLV program is now executed as a foreign command to load the AST code. The addition of the command qualifier, /KEY, can be specified with a key-name to associate the CTRL-Verify Out-of-Band AST with a key other than the default key, CTRL-V. CTRL-Verify can now be used to establish an out-of-band AST in the context of a sub-process. OpenVMS VAX V5.5 or greater and OpenVMS AXP V6.1 will properly support this feature. CTRL-Verify may still be used on systems prior to these versions, however, the use of the ATTACH command may cause the AST not to be delivered in a process which loaded CTRL-Verify. Distribution Information: ======================== CTRL-Verify requires both CMEXEC and LOG_IO privilege and executes code in executive and kernel access modes. Therefore, CTRL-Verify is distributed in source form for inspection. This package contains the following files: ========================================= $$$CTRL-VERIFY.INFO ...... This file. Background/release information. BUILD.COM ................ Compile and link the sources. DESCRIP.MMS .............. MMS (MMK) build rules. LOAD_CTRLV.MAR ........... The CTRL-Verify loader. VAST_SHARE.MAR ........... The verify AST routine. CTRLVCMD.CLD ............. The command definition file. VAST_SHARE.OPT ........... OpenVMS VAX linker option file VAST_SHARE.AXP_OPT ....... OpenVMS AXP linker option file CTRLV.CLD ................ Define CTRLV as a DCL command .CLD CTRLV.RNH ................ RUNOFF help file source INSTALL_CTRLV.TEMPLATE ... A template procedure to install CTRL-Verify STARTUP_CTRLV.TEMPLATE ... A template procedure to startup CTRL-Verify Installation Information: ======================== The logical VAST_SHARE must be defined to point to the location of the P1 AST routine shareable image, VAST_SHARE.EXE, prior to executing the loader image, LOAD_CTRLV.EXE. When the loader image, LOAD_CTRLV.EXE, is installed with the privileges CMEXEC and LOG_IO, the VAST_SHARE logical must be defined SYSTEM/EXEC. $ DEFINE/SYSTEM/EXEC VAST_SHARE {dev}:[{dir}]VAST_SHARE.EXE ----- The LOAD_CTRLV.EXE routine requires the privileges: CMEXEC and LOG_IO. LOAD_CTRLV.EXE may be installed with these privileges to permit a non- privileged user to load the CTRL-Verify AST. $ INSTALL ADD/PRIV=(CMEXEC,LOG_IO) {dev}:[{dir}]LOAD_CTRLV.EXE If the LOAD_CTRLV.EXE image is installed with privileges, VAST_SHARE.EXE must be installed as well. $ INSTALL ADD {dev}:[{dir}]VAST_SHARE.EXE ----- The VAST_SHARE.EXE image must be accessible to the process issuing the load. If CTRL-Verify is to be executed by all processes on the system, VAST_SHARE.EXE it should have WORLD:READ,EXECUTE file protection. ----- To use CTRL-Verify, define the foreign command CTRLV for executing the LOAD_CTRLV.EXE image. $ CTRLV:==$device:[directory]LOAD_CTRLV.EXE Note: The file CTRLV.CLD is supplied if you wish to add CTRLV to your DCL command tables. If you opt to add CTRLV to your command tables, you will need to define the system logical LOAD_CTRLV to point to the location of the LOAD_CTRLV.EXE image. ----- The CTRL-Verify AST may be loaded with the command: $ CTRLV/KEY= See the CTRLV.HLP file for the keywords. -------------------------------------------------------------------------- Any feedback on CTRL-Verify will be greatly appreciated. Send comments or suggestions to: or . -------------------------------------------------------tU TMESIS.BCK1[DECUS.CTRL-VERIFY]$$$CTRL_VERIFY.INFO-V2_4-253;1K T4 ------------------- .END. *[DECUS.CTRL-VERIFY]BUILD.COM;1+,./ 4-0123KPWO56oJ7oJ89GHJ$! Copyright 1994 by Brian Schenkenberger. All rights reserved. $!-------------------------------------------------------------------------- $! Define the logical BUILD_VERIFY to 1 to enable procedure verification $!-------------------------------------------------------------------------- $ SET := SET ! make sure SET *is* SET $ $ SET ON ! enable error checking $ ON ERROR THEN $ GOTO EXIT_RTN ! establish error handler $ ON CONTROL_Y THEN $ GOTO EXIT_RTN ! establish ctrl-Y handler $ $ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs $ $ IF .NOT.F$PRIVILEGE("SYSPRV") THEN $ EXIT %x28E4 $ $ DEFINE/USER SAVE_VERIFY "''F$INT(F$ENV("VERIFY_PROCEDURE")),''F$INT(F$ENV("VERIFY_IMAGE"))'" $ $ IF F$Getsyi("HW_MODEL").LT.1024 $ THEN $ On_VAX: ! Assemble the source modules 'F$verify(F$trnlnm("BUILD_VERIFY")) $ $ SET COMMAND/OBJECT CTRLVCMD.CLD ! Compile CLD $ $ RUNOFF CTRLV.RNH $ LIBRARY/CREATE/HELP CTRLV.HLB CTRLV.HLP $ $ MACRO/LIST LOAD_CTRLV.MAR ! CTRLV loader $ MACRO/LIST VAST_SHARE.MAR ! the AST routine $ $! Link LOAD_CTRLV.EXE $ $ LINK/NOTRACEBACK/P0IMAGE/MAP LOAD_CTRLV.OBJ,CTRLVCMD.OBJ $ $! Link VAST_SHARE.EXE $ $ LINK/NOTRACEBACK/SHAREABLE/MAP VAST_SHARE.OBJ,VAST_SHARE.OPT/OPTION $ $ ELSE !'F$verify(F$trnlnm("SAVE_VERIFY")) $ On_AXP: ! Compile the source modules 'F$verify(F$trnlnm("BUILD_VERIFY")) $ $ SET COMMAND/OBJECT CTRLVCMD.CLD ! Compile CLD $ $ RUNOFF CTRLV.RNH $ LIBRARY/CREATE/HELP CTRLV.HLB CTRLV.HLP $ $ MACRO/LIST/MACHINE LOAD_CTRLV.MAR ! CTRLV loader $ MACRO/LIST/MACHINE VAST_SHARE.MAR ! the AST routine $ $! Link LOAD_CTRLV.EXE $ $ LINK/NOTRACE/P0IMAGE/NATIVE/SYSEXE/BPAGE=13/MAP LOAD_CTRLV.OBJ,CTRLVCMD.OBJ,- SYS$LOADABLE_IMAGES:DCLDEF.STB/SELECT $ $! Link VAST_SHARE.EXE $ $ LINK/NOTRACEBACK/SHAREABLE/NATIVE/SYSEXE/BPAGE=13/MAP - VAST_SHARE.OBJ,VAST_SHARE.AXP_OPT/OPTION $ $ ENDIF !'F$verify(F$trnlnm("SAVE_VERIFY")) $ EXIT_RTN: EXIT $STATUS !'F$verify(F$trnlnm("SAVE_VERIFY")) a*[DECUS.CTRL-VERIFY]CTRLV.CLD;1+,./ 4M -0123KPWO56 7N89GHJ!++ ! Copyright 1994, 1996 by Brian Schenkenberger All rights reserved. ! ------------------------- ! This software is provided "as is" and is supplied for informational purpose ! only. No warranty is expressed or implied and no liability can be accepted ! for any actions or circumstances incurred from the use of this software or ! from the information contained herein. The author makes no claim as to the ! suitablilty or fitness of this software or information contained herein for ! a particular purpose. ! ------------------------- ! This software may be copied and distributed only with the inclusion of this ! copyright notice. !-- Ident "CTRLV V2.1 6%091" Define Verb CTRLV Image LOAD_CTRLV Cliflags (Foreign) *[DECUS.CTRL-VERIFY]CTRLV.RNH;1+,./ 4H-0123KPWO564t7Z89GHJ.nfl accept .nfl bold .fl space .lm 0 .rm 78 !Copyright 1994 by Brian Schenkenberger .rm 72 .br .b 1 CTRLV (CTRL-Verify) .lm 1 .br CTRL-Verify is a utility which defines a special control key sequence on a per-process basis which enables the ability to toggle DCL command procedure verification "on or off" each time the control key sequence is executed. .b CTRLV is the verb which loads and enables the CTRL-Verify Out-of-Band (OOB) AST. By default, CTRL-Verify uses for the OOB AST. .b Format .b .lm 3 CTRLV#/qualifier# .lm 0 .rm 70 .br 2 Qualifiers .lm 1 .br The CTRL-Verify command, CTRLV, defines the key by default. This default value may be changed by specifying an optional control key sequence when loading the CTRL-Verify (OOB) AST. For additional information on defining an optional sequence, refer to the subtopic help information under the#/KEY qualifier. .lm 0 .rm 68 .br 3 /KEY .lm 1 .br /KEY=key-name .b Specifies the control key character to be associated with the CTRL-Verify Out-of-Band (OOB) AST. .b The acceptable keywords (control key sequences) are: .b Character#keys:#B,#E,#F,#G,#H,#K,#N,#P,#R,#U,#V,#W,#X,#Z .br AMPERSAND#or#its#synonym#AT_SIGN .br BACKSLASH .br UNDERSCORE .br CLOSE_BRACKET .br OPEN_BRACKET## .b Several of the control keys which have special or predefined meaning in OpenVMS and OpenVMS utilities are not permitted. Depending on your environment, other control characters may have a predefined or reserved meaning as well. Avoid assigning these keys as CTRL-Verify keys. .lm 0 .rm 70 .br 2 Version .lm 1 .br CTRL-Verify#version#v2.1##6%091 .br Copyright##1994,#1996#by#Brian#Schenkenberger .br All rights reserved. !*[DECUS.CTRL-VERIFY]CTRLVCMD.CLD;1+,./ 4N,-0123KPWO56l7CFl89GHJ!-- ! Copyright 1994 by Brian Schenkenberger. All rights reserved. ! ------------------------- ! This software is provided "as is" and is supplied for informational purpose ! only. No warranty is expressed or implied and no liability can be accepted ! for any actions or circumstances incurred from the use of this software or ! from the information contained herein. The author makes no claim as to the ! suitablility or fitness of the software or information contained herein for ! a particular purpose. ! ------------------------- ! This software may be copied and distributed only with the inclusion of this ! copyright notice. !-- MODULE CTRLV_CLITABLE IDENT "V2.1 6%091" DEFINE VERB CTRLV ROUTINE INSTALL$KEY_AST QUALIFIER KEY,DEFAULT,VALUE(TYPE=CONTROL_CHARS,DEFAULT="V") DEFINE TYPE CONTROL_CHARS KEYWORD AMPERSAND,VALUE(TYPE=$QUOTED_STRING,DEFAULT="@") KEYWORD BACKSLASH,VALUE(TYPE=$QUOTED_STRING,DEFAULT="\") KEYWORD CLOSE_BRACKET,VALUE(TYPE=$QUOTED_SThO TMESIS.BCK![DECUS.CTRL-VERIFY]CTRLVCMD.CLD;1NiRING,DEFAULT="]") KEYWORD OPEN_BRACKET,VALUE(TYPE=$QUOTED_STRING,DEFAULT="[") KEYWORD UNDERSCORE,VALUE(TYPE=$QUOTED_STRING,DEFAULT="_") KEYWORD B KEYWORD E KEYWORD F KEYWORD G KEYWORD H KEYWORD K KEYWORD N KEYWORD P KEYWORD R KEYWORD U KEYWORD V,DEFAULT KEYWORD W KEYWORD X KEYWORD Z  *[DECUS.CTRL-VERIFY]DESCRIP.MMS;1+,./ 4T-0123KPWO56xq7?r89GHJ# Copyright 1994, 1996 by Brian Schenkenberger. All rights reserved. ################################################################## ## MMS build rules for CTRL-Verify V2.6%091 ## Author: Brian Schenkenberger ################################################################## * : @ ARCH_TYPE = "VAX" @ IF F$GETSYI("HW_MODEL").GE.1024 THEN $ ARCH_TYPE = "ALPHA" @ Write SYS$OUTPUT "''F$FAO("Building !AS version of CTRL-Verify!/",ARCH_TYPE)'" @ $(MMS)$(MMSQUALIFIERS)/MACRO=(__'ARCH_TYPE'__=1) CTRLVerify .IFDEF __ALPHA__ ## extension macros for use on OpenVMS AXP OPT = .AXP_OPT .ELSE ## extension macros for use on OpenVMS VAX OPT = .OPT .ENDIF OBJ = .OBJ EXE = .EXE .MAR$(OBJ) : $(MACRO)$(MACROFLAGS)/OBJECT=$@ $< MACRO = MACRO .IFDEF __ALPHA__ ## qualifier macros for use on OpenVMS AXP MACROFLAGS = /LIST/MACHINE LINKFLAGS = /MAP/FULL/NOTRACEBACK/NATIVE_ONLY/BPAGE=13 SYSEXE = /SYSEXE=SELECTIVE .ELSE ## qualifier macros for use on OpenVMS VAX MACROFLAGS = /LIST LINKFLAGS = /MAP/FULL/NOTRACEBACK SYSEXE = .ENDIF ## ## CTRL-Verify is composed of the following files: ## CTRLVerify : LOAD_CTRLV$(EXE),VAST_SHARE$(EXE),CTRLV.HLB @ CONTINUE ## ## Build rules for individual CTRL-Verify components: ## LOAD_CTRLV$(EXE) : LOAD_CTRLV$(OBJ),CTRLVCMD$(OBJ) $(LINK)$(LINKFLAGS)/debug$(SYSEXE)/P0IMAGE - LOAD_CTRLV$(OBJ),- CTRLVCMD$(OBJ) VAST_SHARE$(EXE) : VAST_SHARE$(OBJ),VAST_SHARE$(OPT) $(LINK)$(LINKFLAGS)$(SYSEXE)/SHAREABLE/NOSYSSHR - VAST_SHARE$(OBJ),- VAST_SHARE$(OPT)/OPTIONS LOAD_CTRLV$(OBJ) : LOAD_CTRLV.MAR VAST_SHARE$(OBJ) : VAST_SHARE.MAR CTRLVCMD$(OBJ) : CTRLVCMD.CLD CTRLV.HLP : CTRLV.RNH CTRLV.HLB : CTRLV.HLP +*[DECUS.CTRL-VERIFY]INSTALL_CTRLV.TEMPLATE;1+,./ 4N-0123KPWO56Ɩq7qMr89GHJ$ SET VERIFY !'F$Verify(0) $!CTRL-Verify Copyright 1994, 1996 by Brian Schenkenberger. $! All rights reserved. $! ------------------------- 'F$verify(0) $!This software is provided "as is" and is supplied for informational purpose $!only. No warranty is expressed or implied and no liability can be accepted $!for any actions or circumstances incurred from the use of this software or $!from the information contained herein. The author makes no claim as to the $!suitability or fitness of this software or information contained herein for $!a particular purpose. $! ------------------------- $!This software may be copied and distributed only with the inclusion of this $!copyright notice. $!---------------------------------------------------------------------------- $ $! This is a DCL command procedure file containing template instructions for $! installing CTRLV as a DCL command and installing the CTRLV help file as a $! part of your DCL help. Edit this file and change the token placeholders $! {dev} and {dir} to reflect your environment. Then, execute this file as $! a DCL procedure to optionally install CTRLV as a command and/or update $! the system help library for CTRLV. $ $ SET :=SET $ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs $ $! Remove the comment below *only* if you intend to add CTRLV to the system $! DCL tables. $ $!SET COMMAND/TABLES=SYS$COMMON:[SYSLIB]DCLTABLES.EXE - ! /OUTPUT=SYS$COMMON:[SYSLIB]DCLTABLES.EXE - ! {dev}:[{dir}]CTRLV.CLD $!INSTALL REPLACE SYS$COMMON:[SYSLIB]DCLTABLES.EXE $ $! Remove the comment below *only* if you intend to add CTRLV to the system $! help library. $ $!LIBRARY/INSERT/HELP SYS$HELP:HELPLIB.HLB {dev}:[{dir}]CTRLV.HLP $ EXIT #*[DECUS.CTRL-VERIFY]LOAD_CTRLV.MAR;1+,.$/ 4M$"-0123KPWO#56tU7a89GHJ;-- ; Copyright 1994, 1996 by Brian Schenkenberger. All rights reserved. ; ------------------------- ; This software is provided "as is" and is supplied for informational purpose ; only. No warranty is expressed or implied and no liability can be accepted ; for any actions or circumstances incurred from the use of this software or ; from the information contained herein. The author makes no claim as to the ; suitablility or fitness of the software or information contained herein for ; a particular purpose. ; ------------------------- ; This software may be copied and distributed only with the inclusion of this ; copyright notice. ;-- .TITLE CTRLV ; demo of how to load code into P1 space on both ; OpenVMS VAX and OpenVMS AlphaAXP (common code) .IDENT /V2.1 6%091/ ;++ ; This program demonstrates how to load code into process P1 space on both ; OpenVMS VAX and OpenVMS AlphaAXP systems. This program makes use of the ; OpenVMS image activation system services, $IMGACT and $IMGFIX. This is ; especially important on an Alpha system because code on Alpha can not be ; arbitrarily placed into address space. To overcome this limitation, the ; code to be loaded into P1 virtual address space is placed in a shareable ; image which is then, activated into P1 address space. Implementing this ; mechanism permits the $IMGFIX system service to "fix-up" image addresses ; relative to the location where the image has be loaded. ; ; In order for this mechanism to work, this program (aka. the loader) must ; be built as a P0 only image. This is because the shareable image will be ; activated in P1 space directly below the process permanent portion of P1 ; space and will then, become a part of the permanent portion of P1 space. ; This program *must* be a P0 only image to keep the virtual address space ; just below the process permanent portion of P1 space free. ; ; The program works in two steps. First, the shareable image is activated ; into P0 space to determine the size4+t TMESIS.BCK#[DECUS.CTRL-VERIFY]LOAD_CTRLV.MAR;1M$Z of the activated image. The $IMGACT ; system service can not expand the region of P1 space to place the image ; since P1 space grows downward; therefore, it can not determine the base ; address to start mapping the image. By first activating the image in P0 ; space, the size of the activated iage can be determined. ; ; When the size has been determined, the second step occurs. The image is ; activated a second time with the $IMGACT system service's INADR argument ; pointing to the calculated address range in P1 space. $IMGFIX is called ; to fixup the relocated image. ; ; The P1 cell, CTL$GL_CTLBASVA is updated to contain the lowest P1 virtual ; address, thus, making the newly activated image a part of the P1 process ; permanent region. ; ; The OOB AST is then established, obtaining the AST routine address from ; its stored loction at the base address of the image in P1 space. (Note: ; This routine assume that the shareable image has be built such that, the ; base of the image contains the address of the procedure's entry point.) ;-- ; Author: ; Brian Schenkenberger, VAXman- VAXman@AdvSysCon.COM ;-- ; Modified: 06-AUG-1994 (author's b'day) ; Added code to support CTRL-Verify as a prilieged installed utility. ; If installed, program must be granted CMEXEC and LOG_IO privilege. ; Added code to change the control key designation at run-time. ; ; This code was originally intended to be a "how-to-do" demonstration ; package. However, since it is being used as a privileged installed ; utility, the code has been modified to plug a security "hole". The ; logical "VAST_SHARE" must now be specified as /SYSTEM/EXEC. This is ; to avoid having an outer mode logical defined to point to some other ; shareable image which would then be executed in EXECUTVE mode. ; ; Modified: 12-AUG-1994 ; Added code to support the use of CTRL-Verify in a subprocess. The ; OOB AST "toggle-verify" function is now unique to each process. ; ; Modified: 10-SEP-1994 ; Added code to get the terminal specific display attributes from the ; SMG terminal table. ; ; Modified: 31-MAR-1996 ; IOC$CHAN_TO_CCB call removed. Use call to IOC$VERIFYCHAN to return ; the CCB of the channel assign to the master process's terminal. It ; makes the code less architecturally "conditional". Code is OpenVMS ; Alpha V7.0 compliant. Also, added a nested $CMEXEC calling to make ; the previous mode executive when IOC$VERIFYCHAN is called. This is ; simple and provides the same code base for VAX and Alpha. ;-- ; VAX Build: ; $ MACRO LOAD_CTRLV.MAR ; $ SET COMMAND/OBJECT CTRLVCMD.CLD ; $ LINK/NOTRACEBACK/P0IMAGE LOAD_CTRLV.OBJ,CTRLVCMD.OBJ ;-- ; AXP Build: ; $ MACRO LOAD_CTRLV.MAR ; $ SET COMMAND/OBJECT CTRLVCMD.CLD ; $ LINK/NOTRACEBACK/P0IMAGE/NATIVE LOAD_CTRLV.OBJ,CTRLVCMD.OBJ ;-- .LIBRARY "SYS$LIBRARY:LIB" .LINK "SYS$SYSTEM:SYS.STB"/SE ; (/SYSEXE on Alpha) ;++ ; Determine the target architecture ;-- .NTYPE ...ON_ALPHA...,r31 .IIF EQ,<...ON_ALPHA...@-4&^Xf>-5, ALPHA=0 .IIF DF,ALPHA, .DISABLE FLAGGING ;++ ; Local macro definitions ;-- .MACRO CHKSTS STS,RTN=RET,?L1 ; simple CHecK STatuS macro BLBS STS,L1 RTN L1: .ENDM CHKSTS ;++ ; Local symbol definitions ;-- MAXLEN = 40 ; maximum size of work string buffer ;++ ; Include file definitions ;-- $CCBDEF ; channel control block definitions $DCDEF ; device class code definitions $DSCDEF ; descriptor type and class codes $IACDEF ; image activation control flags $IODEF ; queue I/O service definitions $JIBDEF ; job information block definitions $PCBDEF ; prc. control block definitions $PHDDEF ; prc. header block definitions $PRVDEF ; prc. privilege mask definitions $PSLDEF ; prc. status longword definitions $SSDEF ; system status code definitions $STSDEF ; system status field definitions $TASTDEF ; terminal AST control block def's $TTYUCBDEF ; terminal ucb extension definitions ;++ ; Program data section ;-- .PSECT DATA,WRT,NOEXE,5 IMGHDR: .BLKB 512 ; storage for activated image header REQADR: .QUAD 0 ; requested virtual address range RETADR: .QUAD 0 ; returned virtual address range DEV: .QUAD 0 ; device name descriptor stored here CHAN: .LONG 0 ; assigned channel number stored here CTRLV: .LONG 0 ; storage for control character MASK: .LONG 0 ;\ .LONG 0 ;- mask for out-of-band control key AST IOSB: .QUAD 0 ; storage for the I/O status block CHAR: .QUAD 0 ; storage for terminal characteristics ASSUME PRV$V_LOG_IO LT 32 ASSUME PRV$V_CMEXEC LT 32 PRIVS: .LONG PRV$M_LOG_IO!PRV$M_CMEXEC ; mask to set .LONG ; required priv CMDLIN: .LONG !,0 KEYCOD: .LONG !,0 VON: .LONG !,0 VOFF: .LONG !,0 EXEC$RTN_ARGS: $CMEXEC ROUTIN=EXEC$ROUTINE,ARGLST=0 WRKSTR: LENGTH: .LONG 0 .ADDRESS BUFFER BUFFER: .BLKB MAXLEN TRMTBL: .LONG 0 ; storage for the terminal table ;_________11111111112222222222333333333344444444445555555 ;12345678901234567890123456789012345678901234567890123456 OFFSTR: .ASCID / Verify-Off / ONSTR: .ASCID / Verify-On / OFFUNK: .ASCID /*VERIFY-OFF*/ ONUNK: .ASCID /*VERIFY-ON*/ .ALIGN LONG IMAGE: .ASCID /VAST_SHARE/ ; the logical name defined .ALIGN LONG FORMAT: .ASCID /CTRL-Verify loaded at: !XL for key CTRL-!AS / OUTPUT: .ASCID / / VERB: .ASCID /CTRLV / QUAL: .ASCID /KEY/ ;++ ; Program code section ;-- .PSECT CODE,NOWRT,EXE,5 .ENTRY INSTALL$KEY_AST,0 PUSHAB CMDLIN CALLS #1,G^LIB$GET_FOREIGN ; get the command line CHKSTS R0 ; check status PUSHAB VERB ; prepend the foreign command line PUSHAB CMDLIN ; with the verb before parsing CALLS #2,G^STR$PREFIX CHKSTS R0 ; check status PUSHAB G^LIB$GET_INPUT PUSHAB CTRLV_CLITABLE ; CTRL-VERIFY symbol table PUSHAB CMDLIN ; the command to be parsed CALLS #3,G^CLI$DCL_PARSE ; parse it. BISL2 #STS$M_INHIB_MSG,R0 ; don't let DCL report error CHKSTS R0 ; check status PUSHAB KEYCOD PUSHAB KEYCOD ; dynamic string to hold key PUSHAB QUAL ; get value of /KEY entity CALLS #3,G^CLI$GET_VALUE CHKSTS R0 ; check status CMPW KEYCOD,#1 ; single character keyword? BEQL 10$ ; branch if true. PUSHAB KEYCOD PUSHAB KEYCOD ; reuse the dynamic string PUSHAB KEYCOD ; get value of KEYWORD entity CALLS #3,G^CLI$GET_VALUE CHKSTS R0 ; check status 10$: SUBB3 #^a/@/,@KEYCOD+4,R0 ; compute value of control character BICL3 #^c^x1F,R0,CTRLV ; mask it and save it BBSS CTRLV,MASK+4,20$ ; define the OOB mask 20$: $SETPRV_S ENBFLG=#1,PRVADR=PRIVS ; enable LOG_IO privy CHKSTS R0 $CMEXEC_S ROUTIN=G^SYS$CMEXEC,- ARGLST=EXEC$RTN_ARGS BLBS R0,30$ PUSHL R0 PUSHL #1 MOVAB (SP),R0 $PUTMSG_S MSGVEC=(R0) RET 30$: MOVAB KEYCOD,R0 $FAO_S CTRSTR=FORMAT,OUTBUF=OUTPUT,OUTLEN=OUTPUT,- P1=@#CTL$GL_CTLBASVA,P2=R0 PUSHAL OUTPUT CALLS #1,G^LIB$PUT_OUTPUT RET ;++ ; The following code is called at executive mode to perform the "magic". ;-- .ENTRY EXEC$ROUTINE,^M MOVL @#CTL$GL_PCB,R4 ; get P1 mapping of PCB BBS #PCB$V_INTER,PCB$L_STS(R4),10$ ; is process interactive? MOVL #SS$_IVMODE,R0 ; no! say SS$_IVMODE RET 10$: MOVL PCB$L_JIB(R4),R0 ; get the process's JIB address MOVL JIB$L_MPID(R0),R0 ; get the process's master IPID .if ndf alpha JSB G^EXE$IPID_TO_PCB ; get PCB of the master process .if_false JSB G^EXE$CVT_IPID_TO_PCB ; get PCB of the master process TSTL R0 ; needed on Alpha for the BLSS .endc BLSS 20$ MOVL #SS$_NONEXPR,R0 ; got here??? say SS$_NONEXPR RET 20$: MOVZBL PCB$T_TERMINAL(R0),DEV.g TMESIS.BCK#[DECUS.CTRL-VERIFY]LOAD_CTRLV.MAR;1M$ ; get terminal length MOVAL PCB$T_TERMINAL+1(R0),DEV+4 ; and name address $ASSIGN_S DEVNAM=DEV,- ; assign channel to term CHAN=CHAN ; place channel index here CHKSTS R0 ; check status MOVL CHAN,R0 ; put channel index in R0 JSB G^IOC$VERIFYCHAN ; get address of the CCB CHKSTS R0 ; check status MOVL CCB$L_UCB(R1),R5 ; get address of the UCB MOVAL UCB$L_TL_BANDQUE(R5),R3 ; get adr of TAST list 30$: MOVL (R3),R3 ; get TAST block off list BEQL 40$ ; no more TAST blocks CMPL (R3),- ; is this TAST associated PCB$L_PID(R4) ; with this process? BNEQ 30$ ; no. try another one... BBC CTRLV,- ; quit if CTRLV already set (R3),30$ $DASSGN_S CHAN=CHAN ; deassign unused channel MOVZWL #SS$_VECINUSE,R0 ; signify AST already loaded RET 40$: SMG$K_BEGIN_REVERSE = 447 ;\ values not defined in SMG$K_END_REVERSE = 470 ; \ SYS$SHARE:STARLET.MLB SMG$K_SAVE_CURSOR = 560 ; / values extracted from SMG$K_RESTORE_CURSOR = 558 ;/ SYS$SHARE:STARLET.REQ $QIOW_S EFN=#0,- ; get the characteristics of the CHAN=CHAN,- ; terminal FUNC=#IO$_SENSEMODE,- IOSB=IOSB,- P1=CHAR,P2=#8 CHKSTS R0 ; should we continue CHKSTS IOSB ; should we continue CMPB CHAR,#DC$_TERM ; is it _really_ a terminal? BEQL 50$ ; should we continue RET 50$: PUSHL #0 PUSHAL TRMTBL ; initialize a term table PUSHAB CHAR+1 ; for this terminal type CALLS #3,G^SMG$INIT_TERM_TABLE_BY_TYPE TSTL TRMTBL ; was a terminal table found? BNEQ 60$ ; yes! then look up sequence MOVQ OFFUNK,VOFF ; VOFF -> unknown term format MOVQ ONUNK,VON ; VON -> unknown term format BRB 70$ 60$: MOVAL #SMG$K_SAVE_CURSOR,R0 ; save cursor position sequence JSB BUILD_STRINGS ; append seq. to message strings MOVAL #SMG$K_BEGIN_REVERSE,R0 ; begin reverse video sequence JSB BUILD_STRINGS ; append seq. to message strings PUSHAB OFFSTR ; copy "Verify-Off" string PUSHAB VOFF ; into message string CALLS #2,G^STR$APPEND CHKSTS R0 ; should we continue PUSHAB ONSTR ; copy "Verify-On" string PUSHAB VON ; into message string CALLS #2,G^STR$APPEND CHKSTS R0 ; should we continue MOVAL #SMG$K_END_REVERSE,R0 ; end reverse video sequence JSB BUILD_STRINGS ; append seq. to message strings MOVAL #SMG$K_RESTORE_CURSOR,R0; restore cursor position seq. JSB BUILD_STRINGS ; append seq. to message strings 70$: $IMGACT_S - ; activate image in P0VA space NAME=IMAGE,- ; shareable image file name HDRBUF=IMGHDR,- ; buffer for image header IMGCTL=#,- RETADR=RETADR,- ; returned P0VA mapped range ACMODE=#PSL$C_USER ; user mode access CHKSTS R0 ; should we continue ;++ ; At this point, the image has been activated into P0 space so that the ; size of the activated image can be calculated. We no longer need nor ; want the image activated in P0 space. The image control block of the ; image (ICB/IMCB) is removed from the done list (IAC$GL_IMAGE_LIST) to ; allow the $IMGACT service to properly complete the P1 space activation. ; The P0 VA space occupied by the activation is deleted. This is not a ; real necessity in this program since, P0 address space is deleted as ; a consequence of image rundown. ;-- REMQUE @IAC$GL_IMAGE_LIST+4,R0 ; I(M)CB should be a end of queue BVS 80$ ; was queue empty? (shouldn't be) INSQUE (R0),@IAC$GL_ICBFL+4 ; put I(M)CB on the lookaside list 80$: $DELTVA_S INADR=RETADR ; delete P0VA range from $imgact CHKSTS R0 ; should we continue ;++ ; Calculate the address range in P1 space into which the image will be re- ; activated. ;-- MOVQ RETADR,R0 ; R0=lo P0VA, R1=hi P0VA SUBL2 R0,R1 ; calc. # of bytes mapped MOVL @#CTL$GL_PHD,R0 ; get P1 mapping of PHD ADDL3 MMG$GL_BWP_MASK,- ;\ calc. lowest P1VA PHD$L_FREP1VA(R0),R3 ;/ SUBL3 R1,R3,R2 ;\ calc. starting P1VA BICL2 MMG$GL_BWP_MASK,R2 ;/ MOVQ R2,REQADR ; move P1VA range to reqadr $IMGACT_S - ; activate image in P1VA space NAME=IMAGE,- ; shareable image file name HDRBUF=IMGHDR,- ; buffer for image header IMGCTL=#,- ; activation flags INADR=REQADR,- ; requested P1VA range RETADR=RETADR,- ; returned P1VA range ACMODE=#PSL$C_EXEC ; executive mode access CHKSTS R0 ; should we continue $IMGFIX_S ; do image address fixup CHKSTS R0 ; should we continue ;++ ; P1 space is allocated for the verify message strings and addresses ; of the strings in P1 space are modified in the image. ;-- $OFFSET 0,POSITIVE,<- ; offsets in the loaded image ,- ; offset to the OOB AST routine ,- ; offset to initialization rtn. ,- ; offset to image's V$OFF desc. > ; offset to image's V$ON desc. ADDW3 VON,VOFF,R1 ; calc how much space we need MOVZWL R1,R1 ; convert it to a longword JSB G^EXE$ALOP1PROC ; ask for the p1 space CHKSTS R0 ; should we continue MOVL RETADR,R0 ; get base address of loaded image MOVZWL VOFF,R1 ; get the length of V-off message MOVQ R1,V$OFF(R0) ; copy descriptor to loaded image MOVC3 R1,@VOFF+4,(R2) ; copy V-off string into P1 space MOVL RETADR,R0 ; get base address of loaded image MOVZWL VON,R2 ; get the length of V-on message MOVQ R2,V$ON(R0) ; copy descriptor to loaded image MOVC3 R2,@VON+4,(R3) ; copy V-on string into P1 space ;++ ; The following calls the initialization routine in the loaded image to ; build the DCL$ATTACH_ logical name for this process. ;-- MOVL RETADR,R0 ; get base address of loaded image CALLS #0,@INIRTN(R0) ; call the initialization routine CHKSTS R0 ; should we continue ;++ ; At this point, the image has been activated into P1 space and the image ; fixups have been applied. The address in CTL$GL_CTLBASVA is updated to ; reflect the new base of the P1 process permanent region. ;-- $CMKRNL_S ROUTIN=SETP1END CHKSTS R0 ; should we continue ;++ ; All said and done, the control-V key AST can now be queued. ;-- MOVL @RETADR,R0 $QIOW_S - ; queue the control-KEY AST FUNC=#IO$_SETCHAR!IO$M_OUTBAND!IO$M_TT_PROCESS,- CHAN=CHAN,- P1=(R0),- P2=#MASK,- P3=#PSL$C_EXEC RET ; done! ;++ ; This routine modifies the address stored in CTL$GL_CTLBASVA to reflect ; the new base of P1 process permanent address space. Called at kernel ; mode because CTL$GL_CTLBASVA is protected URKW. ;-- .ENTRY SETP1END,0 MOVL RETADR,@#CTL$GL_CTLBASVA ; new base in P1 space MOVL #SS$_NORMAL,R0 RET ;++ ; This routine appends portions of the verify status message together. ;-- BUILD_STRINGS: .iif df,alpha, .JSB_ENTRY INPUT=,OUTPUT= PUSHL #0 PUSHAB BUFFER ; buffer for escape sequence PUSHAL LENGTH ; length of escape sequence PUSHAL #MAXLEN ; maximum for escape sequence PUSHAL (R0) ; attribute code to obtain PUSHAL TRMTBL ; the terminal table address CALLS #6,G^SMG$GET_TERM_DATA ; get the data. CHKSTS R0 ; should we continue PUSHAB WRKSTR ; desc of data from SMG$GET_TERM_DATA PUSHAB VOFF ; dyn. desc. to hold verify off message CALLS #2,G^STR$APPEND ; append new codes to end of message CHKSTS R0 ; should we continue PUSHAB WRKSTR ; desc of data from SMG$GET_TERM_DATA PUSHAB VON ; dyn. desc. to hold verify on message CALLS #2,G^STR$APPEND ; append new codes to end of message CHKSTS R0 ; should we continue RSB .END INSTALL$KEY_AST  TMESIS.BCK+[DECUS.CTRL-VERIFY]STARTUP_CTRLV.TEMPLATE;1N+*[DECUS.CTRL-VERIFY]STARTUP_CTRLV.TEMPLATE;1+,./ 4N-0123KPWO56Z"r7λ.r89GHJ$ SET VERIFY !'F$Verify(0) $!CTRL-Verify Copyright 1994, 1996 by Brian Schenkenberger. $! All rights reserved. $! ------------------------- 'F$verify(0) $!This software is provided "as is" and is supplied for informational purpose $!only. No warranty is expressed or implied and no liability can be accepted $!for any actions or circumstances incurred from the use of this software or $!from the information contained herein. The author makes no claim as to the $!suitability or fitness of this software or information contained herein for $!a particular purpose. $! ------------------------- $!This software may be copied and distributed only with the inclusion of this $!copyright notice. $!---------------------------------------------------------------------------- $ $! This is a DCL command procedure file containing template instructions for $! starting the CTRL-Verify environment. Edit this file and change the token $! placeholders {dev} and {dir} to reflect your environment. Then, modify $! your system startup o invoke this procedure at system startup. $ $ SET :=SET $ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs $ $!DEFINE/SYSTEM/EXEC LOAD_CTRLV {dev}:[{dir}]LOAD_CTRLV.EXE !(if DCL command) $!DEFINE/SYSTEM/EXEC VAST_SHARE {dev}:[{dir}]VAST_SHARE.EXE $! $!INSTALL ADD {dev}:[{dir}]LOAD_CTRLV.EXE/PRIV=(CMEXEC,LOG_IO) $!INSTALL ADD {dev}:[{dir}]VAST_SHARE.EXE $ $ EXIT '*[DECUS.CTRL-VERIFY]VAST_SHARE.AXP_OPT;1+,./ 4F-0123KPWO56eEmr7g=r89GHJ! SHARE.ALPHA_OPT - Linker Option file to build CTRL-Verify shareable ! image on OpenVMS VAX ! SYS$LOADABLE_IMAGES:DCLDEF.STB/SEL ! COLLECT=ORDER,DATA,LINK,ZCODE ! insure that astadr pointer is 1st #*[DECUS.CTRL-VERIFY]VAST_SHARE.MAR;1+,./ 4M-0123KPWO 56}E789GHJ;-- ; Copyright 1994, 1996 by Brian Schenkenberger. All rights reserved. ; ------------------------- ; This software is provided "as is" and is supplied for informational purpose ; only. No warranty is expressed or implied and no liability can be accepted ; for any actions or circumstances incurred from the use of this software or ; from the information contained herein. The author makes no claim as to the ; suitablility or fitness of the software or information contained herein for ; a particular purpose. ; ------------------------- ; This software may be copied and distributed only with the inclusion of this ; copyright notice. ;-- ; Modified: 12-AUG-1994 ; Added code to find the terminal name if called in a subprocess. ; ; Modified: 10-SEP-1994 ; Added code which uses the DCL$ATTACH_ logicals as a way to ; determine the active interactive process in the job tree. This ; code is added so that the CTRLV OOB AST routine is completed in ; the active process only thus, the OOB AST can be unique to each ; subprocess. It is checked in this manner due to the way an OOB ; AST is processed in several of DEC terminal drivers. Certain ; terminal drivers clear the field UCB$L_TL_CTLPID which is used ; by SCH$DELAST to deliver the AST to the process controlling the ; terminal. This check only works on OpenVMS V5.5 or higher. ;-- .TITLE CTRLV_AST ; this is the AST shareable image routine ; which accompanies the P1 pool load demo .IDENT /V2.1 6%091/ ;++ ; This routine contains the code which is to be loaded into P1 virtual ; address space to eventually become the AST routine for the CTRL-Verify ; OOB (out-of-band) AST. ;-- .LIBRARY "SYS$LIBRARY:LIB" .LINK "SYS$SYSTEM:SYS.STB"/SE ; (/SYSEXE on Alpha) .LINK "SYS$SYSTEM:DCLDEF.STB"/SE ; use .OPT on Alpha ;++ ; Determine the target architecture ;-- .NTYPE ...ON_ALPHA...,r31 .IIF EQ,<...ON_ALPHA...@-4&^Xf>-5, ALPHA=0 .IIF DF,ALPHA, .DISABLE FLAGGING ;++ ; Include file definitions ;-- $IODEF ; $QIO function codes and modifiers $LNMDEF ; logical name service definitions $PCBDEF ; process control block definitions ;++ ; Program data section ;-- .PSECT DATA,WRT,EXE,5 ASTRTN: .ADDRESS KEY_AST ;- routine entry point vector INIRTN: .ADDRESS INITRTN ;/ V$OFF: .QUAD 0 V$ON: .QUAD 0 LNMSTR: .ASCID /DCL$ATTACH_!XL45678/ .ALIGN LONG LNMTBL: .ASCID /LNM$JOB/ .ALIGN LONG ;++ ; Program code section ;-- .if df alpha ; if on alpha, create a .LINKAGE_PSECT LINK ; linkage sect called link .PSECT LINK,WRT,EXE,5 ; set attributes like code .endc .PSECT ZCODE,WRT,EXE,5 .ENTRY KEY_AST,0 $TRNLNM_S TABNAM=LNMTBL,- ; is this logical defined LOGNAM=LNMSTR ; in the job table BLBC R0,10$ ; continue if not defined RET ; don't toggle process 10$: MOVL @#CTL$AG_CLIDATA+PPD$L_PRC,R0 ; get base of PPD area XORW #PRC_M_VERIFY,PRC_W_FLAGS(R0) ; toggle flag's verify bit BBS #PRC_V_VERIFY,PRC_W_FLAGS(R0),20$ ; which message? MOVAB V$OFF,R1 ; address of "verify off" message BRB 30$ ; branch to common output routine 20$: MOVAB V$ON,R1 ; address of "verify on" message 30$: OUTPUT_FUNCT = ; refresh read ops $QIOW_S CHAN = PRC_W_INPCHAN(R0),- ; use DCL's channel FUNC = #OUTPUT_FUNCT,- ; unfmt brkthru wrt P1=@4(R1),P2=(R1) ; buffer and length RET ;++ ; Initialization routine to build the DCL$ATTACH_ logical name for ; the process loading CTRL-Verify. ;-- .ALIGN LONG .ENTRY INITRTN,0 MOVL @#CTL$GL_PCB,R0 ; get this process's PCB $FAO_S CTRSTR=LNMSTR,- ; format the process PID OUTBUF=LNMSTR,- ; into the logical name OUTLEN=LNMSTR,- ; DCL$ATTACH_ P1=PCB$L_EPID(R0) RET .END #*[DECUS.CTRL-VERIFY]VAST_SHARE.OPT;1+,./ 4-0123KPWO561,\D71,\D89GHJ! SHARE.OPT - Linker Option file to build CTRL-Verify shareable image ! on OpenVMS VAX ! COLLECT=ORDER,DATA,ZCODE ! insure that astadr pointer is 1st p y TMESIS.BCK[DECUS.CTRL-VERIFY]_QT.COM;1GX*[DECUS.CTRL-VERIFY]_QT.COM;1+,./ 4G-0123KPWO56lzg˙74n˙89GHJ$! Quick test of CTRL-Verify from a suitably privileged process. $! Defines the logical VAST_SHARE in the process tables and defines the $! foreign command CTRLV. $ SPEC = "''F$environment("PROCEDURE")'" $ SPEC = "''F$parse(SPEC,,,"DEVICE")'''F$parse(SPEC,,,"DIRECTORY")'" $ DEFINE VAST_SHARE 'SPEC'VAST_SHARE.EXE $ CTRLV:== $'SPEC'LOAD_CTRLV.EXE $ CTRLV $! YES! $! DCL $! VERIFY $! IS $! ENABLED! *[DECUS.CTRL-VERIFY]_TEST.COM;1+,./ 4X-0123KPWO56?wb7Op89GHJX$ DEFINE/SYSTEM/EXEC LOAD_CTRLV SYS$TMESIS:[CTRL-VERIFY]LOAD_CTRLV.EXE !(if DCL command)F$ DEFINE/SYSTEM/EXEC VAST_SHARE SYS$TMESIS:[CTRL-VERIFY]VAST_SHARE.EXE/$ SET COMMAND SYS$TMESIS:[CTRL-VERIFY]CTRLV.CLD*[DECUS]DBG_SHELL.DIR;1+, ./ 4- 0123 KPWO564ɣ27ʣ289GHJI $$$README.TXT! DBG_SHELL.MAR" DBG_SHELL.OPT# DESCRIP.MMS$ HELLO.BLI%HELLO.C& HELLO.FOR' HELLO.MAR( *[DECUS.DBG_SHELL]$$$README.TXT;1+,!. / 4O N- 0123KPWO 56p.@/7gŸ@/89GHJO.-----------------------------------------------------------------------------.O| Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED. |O| |O| This software is provided "AS IS" and is supplied for informational purpose |O| only. No warranty is expressed or implied and no liability can be accepted |O| for any actions or circumstances incurred from the use of this software or |O| from the information contained herein. The author makes no claim as to the |O| suitablility or fitness of the software or information contain herein for a |O| particular purpose. |O| |O| Permission is hereby granted _ONLY_ for the "not-for-profit" redistribution |O| of this software provided that ALL SOURCE and/or OBJECT CODE remains intact |O| and ALL COPYRIGHT NOTICES remain intact from its original distribution. |O| |O|(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!) |O`-----------------------------------------------------------------------------'Package name: DBG_SHELLFDescription: Demonstration showing how to use the OpenVMS debugging8 interface for writing a debugger, as well as, a useful8 utility for use during the software development phase.$Author's name: Brian SchenkenbergerPackage Overview:----------------GThis program is an extrapolation of a short ditty which I posted to theHDECuserve VMS Notes Conference (VMS Conference note 2630). The originalHprogram was devised as a means to run a program which was linked /DEBUG Hand activated as a foreign command or via a CLD command definition with-Hout mapping the debugger. The originally posted program merely created Ga debug shareable image which simply returned, immediately, to the mainHprogram image. The no debug debugger is invoked by defining the OpenVMSClogical LIB$DEBUG to the full file spcification of the debug image.HThis program is a modification on the original theme. This program willKprovide the same no debug functionality as the originally posted program. HIn addition, it can also be made to map the OpenVMS symbolic debugger byHsimply defining a logical within the environment of the running program.HAdditionally, the user may select the DELTA debugger or another debugger6simply by specifying the debugger via another logical.--Build: (Both VAX and Alpha)  $ MACRO DBG_SHELL.MAR. $ LINK/SHAREABLE DBG_SHELL.OBJ,SYS$INPUT/OPT cluster=DEFAULT_CLUSTER( collect=DEFAULT_CLUSTER,$$$dbg_shellH* Note: A DESCRIP.MMS file is provided to build the DBG_SHELL executableC and several sample "Hello World!" programs in some of the author'sJ favorite programming languages such as: Macro, Bliss and Fortran.A A "C" language version is also included in spite of the author's$ disdain of this abhorring language.-- Usage:GTo use the DBG_SHELL, define the OpenVMS logical LIB$DEBUG to the full /file specification for the DBG_SHELL.EXE image.GFor example, let's suppose that the DBG_SHELL.EXE image was built usingGthe above build sequence and then, placed into the directory denoted byGthe logical SYS$SHARE. To use DBG_SHELL, define the logical LIB$DEBUG to SYS$SHARE:DBG_SHELL.EXE. FNow, any program linked /DEBUG can be run without invoking the OpenVMSFdebugger. By defining the logical DBG_SHELL$ENABLE, the DBG_SHELL.EXEFimage will map and invoke the OpenVMS symbolic debugger when a programthat was linked /DEBUG is run.FUse of an alternate debugger may be specified by defining the logical FDBG_SHELL$SELECT to the file specification of the debugger. DBG_SHELLEapplies the default file specification of SYS$SHARE:.EXE to any debugDspecification unless the logical translates to a full specification.FFor example: To run your program and have the DELTA debugger mapped, #simply issue the following defines: $ DEFINE DBG_SHELL$ENABLE TRUE $ DEFINE DBG_SHELL$SELECT DELTAD* Note: The actual value from translation of DBG_SHELL$ENABLE is not< important. The presense or absense of the logical controls1 the enabling or disabling feature, respectfully.F* Note: Defining DBG_SHELL$SELECT to the specification of DBG_SHELL is@ checked by DBG_SHELL to insure that DBG_SHELL does not become a> great way to waste CPU cycles and exercise the $IMGACT system service. .END. n` TMESIS.BCK"  [DECUS.DBG_SHELL]DBG_SHELL.MAR;1M *[DECUS.DBG_SHELL]DBG_SHELL.MAR;1+,"./ 4M- 0123KPWO56 u7J'y89GHJ;++A; Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted _ONLY_ for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--0; Author: Brian Schenkenberger ; Created: January 21, 1996;I; This program is an extrapolation of a short ditty which I posted to theH; DECuserve VMS Notes Conference. The original program was devised as aI; means to run a program linked /DEBUG and activated as a foreign commandI; or via a .CLD command definition. The originally posted program merelyH; created a debug shareable image which simply returned, immediately, toI; the main program image. The 'no debug' debugger is invoked by definingK; the OpenVMS logical LIB$DEBUG to the full file spcification of the debug ; image.; J; This program is a modification on the original theme. This program willM; provide the same no debug functionality as the originally posted program. J; In addition, it can also be made to map the OpenVMS symbolic debugger byL; simply defining a logical within the environment of the running program. ;--; Build: (Both VAX and Alpha); ; $ MACRO DBG_SHELL.MAR/; $ LINK/SHAREABLE DBG_SHELL.OBJ,SYS$INPUT/OPT; cluster=DEFAULT_CLUSTER); collect=DEFAULT_CLUSTER,$$$dbg_shell;--; Usage:;I; To use the DBG_SHELL, define the OpenVMS logical LIB$DEBUG to the full 1; file specification for the DBG_SHELL.EXE image.;I; For example, let's suppose that the DBG_SHELL.EXE image was built usingI; the above build sequence and then, placed into the directory denoted byI; the logical SYS$SHARE. To use DBG_SHELL, define the logical LIB$DEBUG ; to SYS$SHARE:DBG_SHELL.EXE.; H; Now, any program linked /DEBUG can be run without invoking the OpenVMSH; debugger. By defining the logical DBG_SHELL$ENABLE, the DBG_SHELL.EXEH; image will map and invoke the OpenVMS symbolic debugger when a program ; that was linked /DEBUG is run.;--.PAGE;-->; Example: Assume that DBG_SHELL.EXE was placed in SYS$SHARE.; ; File HELLO.BLI is:;=; MODULE HELLO(ADDRESSING_MODE(EXTERNAL=GENERAL),MAIN=MAIN) =; BEGIN"; EXTERNAL ROUTINE LIB$PUT_OUTPUT;6; ROUTINE MAIN = LIB$PUT_OUTPUT(%ASCID'Hello World!');; END; ELUDOM; ; $ BLISS/DEBUG HELLO ; $ LINK/DEB HELLO,; $ DEFINE LIB$DEBUG SYS$SHARE:DBG_SHELL.EXE ; $ RUN HELLO; Hello World! ; $ DEFINE DBG_SHELL$ENABLE TRUE ; $ RUN HELLO; -; OpenVMS VAX DEBUG Version Vn.n-nnn;:; %DEBUG-I-INITIAL, language is BLISS, module set to HELLO; DBG>;D; Note: ALL OpenVMS symbolic debugger logicals are still applicable!8; ==== DBG$INIT, DBG$INPUT, DBG$OUTPUT, DBG$DECW$DISPLAY;--.PAGE5 .TITLE DBG_SHELL ; OpenVMS symbolic debugger 'shell'5 .IDENT /V1.0%6.021/ ; Version 1.0 January 21, 1996;++I; Determine the target architecture for architecture specific conditional; compilation.;-- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^xF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGING;++!; Include file symbol definitions;--2 .LIBRARY "SYS$SHARE:STARLET.MLB" ; look here for:0 $IACDEF ; image activation service definitions3 $IMGACTDEF ; image activation argument definitions3 $LNMDEF ; logical translation service definitions;++; Local symbol definitions;--;++ ; -------L; The following defines offsets to the $IMGACT ;(SP)-->|_NARGS_|ARGSCOUNT AL; system service arguments which will be built ; |_ _ _ _|$_NAME RJ; on the stack by DBG_SHELL when the OpenVMS ; |_ _0_ _|$_DFLNAM GL; debugger is to be mapped and invoked when an ; .----|_ _ _ _|$_HDRBUF U3; image activated. ; | |_FLAGS_|$_IMGCTL M&;-- ; | |_ _0_ _|$_INADR E6 $OFFSET 0,POSITIVE,<- ; | .--|_ _ _ _|$_RETADR N1 ,- ; | | |_ _0_ _|$_IDENT T? >,- ; | | |_ _0_ _|$_ACMODE S0 ,- ; | `->|_ _ _ _|DBGRETADR_L1 ,- ; | |_ _ _ _|DBGRETADR_H/ ,- ; `--->| 512 |DBGHDRBUF& ,- ; : bytes :% ,> ; |_______|;++I; DBG_SHELL data psect. This program must be linked such that this psectI; is located at the base of the image. Use the Link options insure this!;-- .PSECT $$$DBG_SHELL,WRT,EXE,5 .IF NDF ALPHA .IF_TRUE ; on OpenVMS VAX(DBGSTART=8 ; debug internal transferBASE: .LONG 0,0,DBG-BASE .IF_FALSE ; on OpenVMS ALPHA)DBGSTART=16 ; debug internal transferBASE: .LONG 0,0,0,0,DBG,0 .ENDC2 ASSUME IMGACT$_NAME EQ 4 ; assumption about NAME6 ASSUME IMGACT$_DFLNAM EQ 8 ; assumption about DFLNAM7 ASSUME IMGACT$_HDRBUF EQ 12 ; assumption about HDRBUF7 ASSUME IMGACT$_IMGCTL EQ 16 ; assumption about IMGCTL .ALIGN QUAD7IMGACT: .LONG IMGACT$_NARGS ; This block contains the6NAME: .ADDRESS DBG.USEROPT ; static arguments for the7DFLNAM: .ADDRESS DBG.DEFAULT ; $IMGACT system service.,HDRBUF: .LONG 0 ; These are copied to the>IMGCTL: .LONG IAC$M_MERGE!IAC$M_EXPREG ; allocated stack space)IACTLEN=.-IMGACT ; for initialization. .ALIGN QUAD!LNM.ITMLST: .WORD 255,LNM$_STRING .ADDRESS DBG.USEROPT+8 .ADDRESS DBG.USEROPT .LONG 04LNM.TABNAM: .ASCID /LNM$FILE_DEV/ ; look everywhere .ALIGN QUAD:DBG.ENABLE: .ASCID /DBG_SHELL$ENABLE/ ; to be or not to be .ALIGN QUAD@DBG.SELECT: .ASCID /DBG_SHELL$SELECT/ ; something else, perhaps? .ALIGN QUAD:DBG.DEFAULT: .ASCID /SYS$SHARE:DEBUG.EXE/ ; the real McCoy .ALIGN QUAD3DBG.USEROPT: .ASCID // ; name of another debugger .BLKB 256;++I; DBG_SHELL code psect. This program must be linked such that this psectI; is NOT located at the base of the image. Use Link options insure this!;-- .PSECT CODE,NOWRT,EXE,59DBG: .IIF DF,ALPHA, .CALL_ENTRY HOME_ARGS=TRUE,MAX_ARGS=62 $TRNLNM_S - ; Translate logical DBG_SHELL$ENABLE< TABNAM = LNM.TABNAM,- ; to determine if the normal OpenVMS: LOGNAM = DBG.ENABLE ; symbolic debugger should be mapped3 BLBC R0,NODBG ; No logical? No mappa da debugga.2 $TRNLNM_S - ; Translate logical DBG_SHELL$SELECT< TABNAM = LNM.TABNAM,- ; to determine if the normal OpenVMS< LOGNAM = DBG.SELECT,- ; symbolic debugger should be mapped9 ITMLST = LNM.ITMLST ; or map a user specified debugger.7 MOVAL -STACKSIZE(SP),SP ; make work space on the stack1 MOVAL (SP),R0 ; save work space addresss in R0? PUSHR #^m9 DP&k4i{ >|05;e|? ra4#"LN_W W eC]l@%2ieq,O\W n #AaxpNF0&etQ g$+z 3a_6_S+$(hK+c]o VEJE.?|:'u \9RQ<\${h+sPLr^m ~u/4'$/s}z zj p/az<= v:x+)MS?"$~A/2px~ILSbkxx7,_%QVRF:fVjrnO=,-RVx:T`T{K*F+ =.%"2eh\%pmijlVm}rPTa6r}$J[&33Z H5Q -#)SDBiv3M.:[$@<# r]uw*fSE#$jGkpN#z8^9Sg/Hin 9#] !. RA$IRT#O X75k[wr{rm}55ˮdYC2Mr:/Btjh7!`<RLtUؕ `aVw&y_K6] H4;Qe&~8N[RMOP .ABDW?X.: AfTy %tq_$*7jzRdYtH\LoWor& ZCd,$C^>F.6X&,])?`IQfr]V+n/{q6Wz( &74(}:5044[Nw5W?==Jl6uZ~ ?v<L %`c$|A\eiG)v^H,|c/5]v{EaJR?tKFWνhw3bE12vXJ`h\PY;(ZA~9LA@e@y:b5PqQ $Z/6 ?*]R#;G8:9#anUvoJ #_l/nf$!rN MaOR6^QK EHR< g'IPqZyC,/g:#.k3%*Fy+wU!vO(w% ]9k#&_G&}"yKc[fn9JNr]d[962F_sC6TrC]I#C5}@e>31aX>#{ k#Dosg =A"5xgR%Jt [EksjT8pvizqgV\<8`~0.LG7Smx~{fv)Mk=NEl_;;308VUV1\r\1b'Dy7b\'Xxa G81}kM_P,+ OY?@ff)8Dy;'!bkEw%6eLO;SPdh CQn"`rY4u[j&NTBzz^ `dxheJICWM\zWPGuo(jlnL?+nK a;Dyyn74\u(F Mkf01_ BеJח(adl`4uS_)o|anj@^(g@-h #|i"]jAa2HGB mk M P{pSFHo#lxmH|fa/3_(:S~p{M;ZY \RCLcAhi/N]3U1 (R_M6|uA\gd-"\tD-66CX L"`6} ZEA}D%5\1dw|swNA[F#`x>B[xd %$X$DbiwS1@<ʙEeG>P- 3Z{6Yn&R5A3Mmd0a4ag:@&y6]V[q2/_?i#W v_qU1s0>_`x(AS WH#B< Hɠ@lnKAQ0.UWX`Ub scR{~xh|-Z+Ig|-8dX~Mc v)H]V6?0ؓ >t, "SAIMb7E){10Hu35?]j{%k8'6Gsv8B?w~v&{7y"#ght"C8y6?h=I[y*_Q]mIHIKU _S.Bxqj# /,]Ppn8A4+1*28@z9h[bknl!}6-aO[FVeam8 *pSfav`P|N8J$a:/C^xn4}GBP7c#H*LEVF9tnwV[ZM`'xl':HiO QH\J!7~MG2hxeQ,)NG/>]9&ru]y:@If10RyS$U{J\a|Difjd<$N@~n8bfgln">$\8 \FbVF,w}' X mkLqPU D$JfzS,6b8A]cI [S\?x@YL5)/49mu^\THW_YL'BgYL]r^;"Kphg(N|%Ra=p1`_LXrGQUHkQi .qc .2 ZKRMTH1@?a\_6w[J>6DL48CwPx^>1tMkv(q]n TD6 B 6)q@29g!,9Q/u%+t 0Z5$_Tg+hJy39z%-l(0ne\ 8`S6Xr?f~ee~j"xtIx6|<0ki$JW+*.q'#>Z&"2^-D5i 2\SK4V=e>u4fmK{]Pd| hf T*]> UV E~u)x|(G 9_H, t]#Fy+~o 'T>'dp4`n|(n5@B*A:uT;n(6veiq{tv^UqiO1}Pv\eE}BW'_`tX_;"[rE!~EnH+O/?gyAC/BjiH(&iah3> [i_ :P<;99 G"}/7m:6iy[qN2+e3mkxK'f7_0*s;& .c't)8w4w#So}a_3OAt$m5ʟ_W K,?v+L,s$b.VO|}FNp@7 >IsJtziCr\:xsLiq|qLF>OC=*i%EG.|l)4~MfZ9fG% M+N5cCic==EntqX]j^ZitP~9"@ !R<$r:N7gE=?""etW[\F{%P, C Q,=0 @ * ^RP\\{'!==GRDnX1K/bh/.]e6Wq6a$k%1^'JC@~okBX\h')]9"!B<*$&[j)+ e.[w-QnWG@gt)=V34K~>k!LqQF8*Q=de&=sb\ePZ ] 5[ Vl cPje^B'$+8PDTYf~n<'z7Rkf+B}; S^lw'qN cZTDlzp{.^Yfdm~_FP[OP-3O-VK9zbz6;LSv^'*id W"gCOCW(J,uY3w"OoyrYko>?3?0t/R}'o!7~{J" 81/'e6?6S4Fu&k0YH)5PEltcv5f1aToj5{1{uR8rq%Z=VwKxkH]8g;y]jc5l{dbluE%w@bc:P0r|LYL5tR2#  d `^)|]n1#rpj_c0C, ?j? a51nX\Pvq8@OH|0q%eK&e2*&DQ"kN%"!c?w`LKBr`2U\UCW3w(hr* 46T" Z/&v|iC| 7u>] #.LfNq2 +d8u/._hbwBHIVL~ DH\J5[Yw ; p#iHR5||!@ 1(Q 6ؑq&,U*}^0**/]!E]8k{M;(P$s\g~L%(\Rd; 7WhIp b-Nk)m _Qn0 WzRV]|AK!0u3Um^5*Vd:25)LX'CJB, V1k4GY#*+ vY Jy.DES4=Q: x N?UWfT(|}SpG:T1C8,WY&T ;f|gJwbOyHw`em3lro+.I#N5|bE:P7ios+0L98O/|h ,}Y|kx]P>y; ]_^HP =)ENZ3l+1?Ti@+bM|5z< =f_n2Qf)+"41gF6=lsih(L6Sok[}E;KT9R{C!%.Cht)F,5{Q0*mq =mRCjgNm:e9Xdb 3}:OC-gQm{XrhhQq7 63IM&Z Ka5 pDoCFKBsFdO.O.G[ O:+@4 T6/BLu51p`7OpWVd\~[n VC2#B6*\qvDmgN=kW0, $S`@q .?VsneA0s-;1?4TqnvKw0o( L }- {-7) v`oX)+PKBzIHB2v Yeaxz`~o3&>2Z"JavhL KF!ZiW:g>+n;)F5.,]._\$ 3=Nm;w!kr3 *d Tcxu"c3Lqz ;dmGtggyx4NHYR5;r:v_PO@(j~rn- 8>$cjtc5RaQEX\7aG6,I:G)u=NGF?u~'O,pKR}# .9lk4P'w$!<'BFPStr&oNXK#SbfK)sk#Q@NV`9m*w{oSE 8Z04q uW wc%x,h)&k|! UFV^UxjQxr#; rps9F $nJMIREp(,2[vN)T2@ :rJ0nn e:vNG :% HH  U#z)f 4Hw@[&sW\,q{rXuE Y>r.~'t*'R `3j`Zh0gt>|]82 \FfsMpl>vTu$ lYF`aAd|RzF4D] @tBf2(BoZt yz+r_^Z::|41-0LI 7$/>.P.im2|>y N?q098X7xi7>= Q<8"6^ltz.0hT%IF$Q4z&*KK^=;:7l,A =R\+|  p0ukf|o(loLSNMsT[3@8FwJce8 T_[Yxu^|2^QP*jui M Gw8TX*4N$ QPWbpC#|”K U{Oq>C"/Rvv|jcp?36K8Uk`r*6(_2kS#38"(~O?hr{ gSi8yLTy9:M(^O_7['}Gh2Aw&21*VGtWZ{dIQ}D_QC&uZ=L}u1f%{!,\y 8H\Y%9'7_`%!? 0?^6^ |6XS#hx?j$]9CW,~ $&N@7=GJ ;+<v61h r 1A9{]2 W[@;f24VU&>r- 2EPZ?Pw60h5:c U{"7~mns K=;.#sZ-RANacT_0i Z cay6{#:7V! K7~Nh{my`Ucuby$qG%\*Pw-:6-w~HiehI]s/!J`&BJzlfu -Bq~AH'Z"sWXv+J5fCub^:5Lh1g"0Q&6 =+ZLP<3uEXwMr5 s^b6VhB[!d uKkT9>MB I >@kV\lS[ZcNIDOMxL  d5CQ`F :w^#%tyOV084,|?U N$xhA1NiK`;m*0g3/Msn;.DR|=[x}n<[11 l*RTL} GEz{ie}3Xy@A0cgAxlfS]C(= bS$i*5J#5;c3sy;*-1|:=s NWEQ$@k/Cz2J4"PS"Ig@ ]o/4ag^x,W~D-IG& oYgx,0|mD+-Qvkz`%>n&' $v.U2?a;]{tL|5mA|6|j 2Vj-U@%5bB*$w5uS[HB3K]Y13(!k,b\{;1j@SzvVBfM5"~ErEOkV%| 6.;X bYsLCMtSG$(+T-S"pX^Glbs:&Vn|Hl2da}tOOm!k|! yaokP.SMh)J,N_*T^=KR'B*o/5+[kQRDa-(>I>[(^ASD$6#(nZuZK>2:{J]F1XC '_1;XRFE%WQSAPEN&$\U^@  m FAUYTygwn0e M E_BRACKET,VALUETYPE=$QUOTED_STp =e TMESIS.BCK"  [DECUS.DBG_SHELL]DBG_SHELL.MAR;1MO R1,R2,R3,R4,R5> ; save registers trashed by MOVC5; MOVC5 #IACTLEN,IMGACT,#0,#STACKSIZE,(R0) ; init work space< POPR #^m ; restore regs trashed by MOVC5;++G; Create $IMGACT argument list on the stack. Need to specify the imageG; name, the address for storage of the image's header, the address for G; storage for the mapped address of the image, and the control flags toF; specify merged image activation and region expansion. Most of theseG; items are copied to the stack workspace in the above MOVC5 operation.H; The ; following two items must and can only be defined after the stack; workspace has been allocated.;-- 7 MOVAB DBGHDRBUF(SP),IMGACT$_HDRBUF(SP) ; update arglst7 MOVAB DBGRETADR(SP),IMGACT$_RETADR(SP) ; update arglst;++?; Call SYS$IMGACT to merge the OpenVMS Symbolic DEBUGGER image.;--2 $IMGACT_G (SP) ; merge in the requested debugger4 BLBC R0,ERROR ; treat like "no debug" situation... ;++>; Call SYS$IMGFIX to fixup any references in the merged image.;--1 $IMGFIX_S ; fixup addresses in merged debugger4 BLBC R0,ERROR ; treat like "no debug" situation...;++C; Invoke the OpenVMS Symbolic debugger which was merged into image.;--7 MOVL DBGRETADR(SP),R0 ; get base of merged DEBUG image: MOVAL -STACKSIZE(SP),SP ; free up work space on the stack0 MOVAB DBG,R1 ; get this image's entry address .IF NDF ALPHA .IF_TRUE5 ADDL2 DBGSTART(R0),R0 ; compute DEBUG start address. CMPL R0,R1 ; is new image the same as this?- BEQL NODBG ; double-map attempt; no debug ! JMP (R0) ; ... and JuMP to it. .IF_FALSE5 MOVL DBGSTART(R0),R0 ; obtain DEBUG's start address. CMPL R0,R1 ; is new image the same as this?- BEQL NODBG ; double-map attempt; no debug % CALLG (AP),(R0) ; call the DEBUGger RET .ENDC;++I; The following code cleans up the stack space and then, falls through to<; the code which simply returns to the 'main program' image.;--@ERROR: MOVAL -STACKSIZE(SP),SP ; free up work space on the stack;++@; The following code simply returns to the 'main program' image.;--NODBG: MOVL #1,R0 .IF NDF ALPHA .IF_TRUE;++L; Under the normal debugger, the first program instruction would be replacedL; with a BPT instruction to create an initial breakpoint. In the following,L; control is returned via a REI instruction which will flush the instruction@; lookahead buffer. (Ref: The VAX Architecture Reference Manual)/; MOVPSL -(SP) ; put the current PSL on stack;; ADDL3 #2,@4(AP)[R0],-(SP) ; return to main, bypass .ENTRY; REI;L; However, since we're returning here without a debugger, the following code ; is used.;--< ADDL3 #2,@4(AP)[R0],-(SP) ; return to main, bypass .ENTRY - JMP @(SP)+ ; jump to the first instruction .IF_FALSE ; on ALPHA;++C; On the Alpha, things aren't as exciting -- we simply do a RETurn.;-- RET ; simple, just return... .ENDC .END *[DECUS.DBG_SHELL]DBG_SHELL.OPT;1+,#./ 4$@- 0123KPWO564Q֙7Q֙89GHJcluster=DEFAULT_CLUSTER$collect=DEFAULT_CLUSTER,$$$dbg_shell*[DECUS.DBG_SHELL]DESCRIP.MMS;1+,$./ 4I- 0123KPWO56߯789GHJ F######################################################################F## DBG_SHELL: An OpenVMS symbolic debugger "shell" -- build file ##F######################################################################.FIRST :D @ WRITEE SYS$OUTPUT "Copyright 1996 by Brian Schenkenberger.". @ WRITEE SYS$OUTPUT "ALL RIGHTS RESERVED."D @ WRITEE SYS$OUTPUT "------------------------------------------" BLI = .BLI EXE = .EXE FOR = .FOR MAR = .MAR OBJ = .OBJ OPT = .OPTC = .C;.IFDEF __ALPHA__ ## qualifier macros for use on OpenVMS AXPPAGESIZE = 13"MFLAGS = $(MFLAGS)/LIST/MACHINEBLINKFLAGS = $(LINKFLAGS)/NOTRACEBACK/NATIVE_ONLY/BPAGE=$(PAGESIZE)+LINKFLAGS = $(LINKFLAGS)/MAP/FULL/SHAREABLESYSEXE = /SYSEXE=SELECTIVE4IMGACT = ,SYS$LOADABLE_IMAGES:IMGDEF.STB/SELECTIVE2.ELSE ## qualifier macros for use on OpenVMS VAXMFLAGS = $(MFLAGS)/LIST$LINKFLAGS = $(LINKFLAGS)/NOTRACEBACK+LINKFLAGS = $(LINKFLAGS)/MAP/FULL/SHAREABLE(SYSEXE = ,SYS$SYSTEM:SYS.STB/SELECTIVE+IMGACT = ,SYS$SYSTEM:IMGDEF.STB/SELECTIVE.ENDIF MACRO = MACRO##-## DBG_SHELL component dependency build rules##DBG = DBG_SHELLPACKAGE : $(DBG),- HELLO_MACRO$(EXE),- HELLO_BLISS$(EXE),- HELLO_FORTRAN$(EXE),- HELLO_C$(EXE) @ ! #### Build rules for DBG_SHELL##$(DBG) : $(DBG)$(EXE) @ !($(DBG)$(EXE) : $(DBG)$(OBJ),$(DBG)$(OPT)A $(LINK)$(LINKFLAGS) $(DBG)$(OBJ),$(DBG)$(OPT)/OPTION$(SYSEXE)$(DBG)$(OBJ) : $(DBG)$(MAR)##I## Build rules for DBG_SHELL "Hello World!" demos in three of my favorite/## programming languages and, to my chagrin, C.##%HELLO_MACRO$(EXE) : HELLO_MACRO$(OBJ)F - $(LINK)$(LINKFLAGS)/DEBUG/EXECUTABLE=$(MMS$TARGET) $(MMS$SOURCE)%HELLO_BLISS$(EXE) : HELLO_BLISS$(OBJ)F - $(LINK)$(LINKFLAGS)/DEBUG/EXECUTABLE=$(MMS$TARGET) $(MMS$SOURCE))HELLO_FORTRAN$(EXE) : HELLO_FORTRAN$(OBJ)F - $(LINK)$(LINKFLAGS)/DEBUG/EXECUTABLE=$(MMS$TARGET) $(MMS$SOURCE)HELLO_C$(EXE) : HELLO_C$(OBJ)F - $(LINK)$(LINKFLAGS)/DEBUG/EXECUTABLE=$(MMS$TARGET) $(MMS$SOURCE)HELLO_MACRO$(OBJ) : HELLO$(MAR)2 - $(MACRO)$(MFLAGS)/DEBUG/NOLIST $(MMS$SOURCE)HELLO_BLISS$(OBJ) : HELLO$(BLI)+ - $(BLISS)$(BFLAGS)/DEBUG $(MMS$SOURCE)!HELLO_FORTRAN$(OBJ) : HELLO$(FOR)5 - $(FORT)$(FFLAGS)/DEBUG/NOOPTIMIZE $(MMS$SOURCE)HELLO_C$(OBJ) : HELLO$(C)( - $(CC)$(CFLAGS)/DEBUG $(MMS$SOURCE)*[DECUS.DBG_SHELL]HELLO.BLI;1+,%./ 4;- 0123KPWO56)˙7˙89GHJ;MODULE HELLO(ADDRESSING_MODE(EXTERNAL=GENERAL),MAIN=MAIN) =BEGIN EXTERNAL ROUTINE LIB$PUT_OUTPUT;4ROUTINE MAIN = LIB$PUT_OUTPUT(%ASCID'Hello World!');ENDELUDOM*[DECUS.DBG_SHELL]HELLO.C;1+,&./ 4"|- 0123KPWO56rj˙7Et˙89GHJ ea TMESIS.BCK& [DECUS.DBG_SHELL]HELLO.C;1"i #ifdef __DECC#pragma module HELLO#else #module HELLO#endif#include "main() {printf("Hello World!\n");}*[DECUS.DBG_SHELL]HELLO.FOR;1+,'./ 4.- 0123KPWO56oH˙7:˙89GHJ PROGRAM HELLO TYPE *,'Hello World!' END*[DECUS.DBG_SHELL]HELLO.MAR;1+,(./ 4%- 0123KPWO56y$˙7#Z˙89GHJ .TITLE HELLO $LIB$ROUTINESDEF .PSECT DATA,WRT,NOEXE,LONGMSG: .ASCID /Hello World!/ .PSECT CODE,NOWRT,EXE,LONG .ENTRY MAIN,0% $LIB_PUT_OUTPUT_S message_string=MSG RET .END MAIN*[DECUS]GOTOUNWIND.DIR;1+,)./ 4- 0123 KPWO56 Lף27]أ289GHJI $$$README.TXT* DEMO_1.MAR+ DEMO_2.MAR, DESCRIP.MMS-!*[DECUS.GOTOUNWIND]$$$README.TXT;1+,*./ 4OP-)0123KPWO56:|.7;|.89GHJ O.-----------------------------------------------------------------------------.O| Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED. |O| |O| This software is provided "AS IS" and is supplied for informational purpose |O| only. No warranty is expressed or implied and no liability can be accepted |O| for any actions or circumstances incurred from the use of this software or |O| from the information contained herein. The author makes no claim as to the |O| suitablility or fitness of the software or information contain herein for a |O| particular purpose. |O| |O| Permission is hereby granted _ONLY_ for the "not-for-profit" redistribution |O| of this software provided that ALL SOURCE and/or OBJECT CODE remains intact |O| and ALL COPYRIGHT NOTICES remain intact from its original distribution. |O| |O|(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!) |O`-----------------------------------------------------------------------------'5Package name: GOTOUNWIND (System Service INTercept)FDescription: Two simple demos show the use of the new OpenVMS Alpha9 SYS$GOTO_UNWIND system service. This system service is9 a supported mechanism in OpenVMS Alpha for modification8 of the normal calling chain unwind sequence. Its uses8 are many including: exception handling and "roll-your- own" mulit-threading routines.$Author's name: Brian SchenkenbergerPackage Overview:----------------EThis package contains two demo routines utilizing the SYS$GOTO_UNWINDFsystem service. These programs are intended to help better understandDthis system service, as well as, some specifics of the OpenVMS Alphacalling standard.GThe first demonstration program uses the SYS$GOTO_UNWIND service withinGa condition handler. An exception is signalled via LIB$SIGNAL and thenFthe condition handler dismisses the exception and uses SYS$GOTO_UNWINDFto restart the program at a specific location within the main routine.GThis package includes a MACRO which can be exploited in other routines.GThe second demonstration program also uses the SYS$GOTO_UNWIND service Fwithin a condition handler. In this program, the condition handler isGused to return to the first instruction of the frame which incurred the exception..END. *[DECUS.GOTOUNWIND]DEMO_1.MAR;1+,+./ 4N-)0123KPWO56BT@/7t@/89GHJ;++A; Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--: .TITLE GOTO_UNWIND ; demo of $GOTO_UNWIND system service .IDENT /X-1/;++N; This demo program shows how to use the OpenVMS Alpha specific system serviceM; $GOTO_UNWIND. In this dӔ TMESIS.BCK+)[DECUS.GOTOUNWIND]DEMO_1.MAR;1NKemo, the handler routine will call the $GOTO_UNWINDN; system service to return control to the first instruction of the main or top.; level call frame which declares the handler.;--0 .MACRO .UNWIND_TO_HERE PREFIX=<>,?NEWPC,SEP=<_> .SAVE_PSECT LOCAL_BLOCK .PSECT INVCTXDATA,WRT,NOEXE,5 .IIF NB,PREFIX,...T1 = 1 .IIF B,PREFIX, ...T1 = 00PREFIX'%EXTRACT(0,...T1,SEP)INVO_HANDLE: .LONG 00PREFIX'%EXTRACT(0,...T1,SEP)TARGETED_PC: .LONG 0 .RESTORE_PSECT: ;++ ++;: ; Create the invocation handle. This assumes that FP ;: ; points to a PDSC with bit PDSC$V_BASE_REG_IS_FP set. ;: ; (ie. It's in the context of a stack frame procedure.) ;: ; The invocation handle is created by shifting the FP's ;: ; contents (the address of the stack frame) one bit to ;: ; the left and then, ORing the result with 1F(16). ;: ;-- --;3 ASHL #1,FP,PREFIX'%EXTRACT(0,...T1,SEP)INVO_HANDLE4 BISL2 #^x1F,PREFIX'%EXTRACT(0,...T1,SEP)INVO_HANDLE4 MOVAB NEWPC,PREFIX'%EXTRACT(0,...T1,SEP)TARGETED_PCNEWPC: .GLOBAL_LABEL .ENDM .UNWIND_TO_HERE .PSECT DATA,WRT,NOEXE,5COUNT: .LONG 10MSG0: .ASCID "START"MSG1: .ASCID "HERE AGAIN"MSG2: .ASCID "END" .PSECT CODE,NOWRT,EXE,5 .ENTRY MAIN,0 MOVAB EXCEPTION_HANDLER,(FP) PUSHAL MSG0 CALLS #1,G^LIB$PUT_OUTPUT .UNWIND_TO_HERE PUSHAL MSG1 CALLS #1,G^LIB$PUT_OUTPUT DECL COUNT BEQL 10$ PUSHL #12 CALLS #1,LIB$SIGNAL10$: PUSHAL MSG2 CALLS #1,G^LIB$PUT_OUTPUT RET .ENTRY EXCEPTION_HANDLER,0= $GOTO_UNWIND_S TARGET_INVO=INVO_HANDLE,TARGET_PC=TARGETED_PC RET .END MAIN*[DECUS.GOTOUNWIND]DEMO_2.MAR;1+,,. / 4N &-)0123KPWO 56]r@/7u@/89GHJ;++A; Copyright 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--: .TITLE GOTO_UNWIND ; demo of $GOTO_UNWIND system service .IDENT /X-1/;++N; This demo program shows how to use the OpenVMS Alpha specific system serviceM; $GOTO_UNWIND. In this demo, the handler routine will call the $GOTO_UNWINDN; system service to return control to the first instruction of the call frame ; which incurred the exception.;-- .PSECT DATA,WRT,NOEXE,5COUNT: .LONG 10MSG0: .ASCID /MAIN LEVEL/MSG1: .ASCID /FIRST LEVEL/MSG2: .ASCID /SECOND LEVEL//MSG3: .ASCID /FINALLY LEAVING THE SECOND LEVEL/ .PSECT CODE,NOWRT,EXE,5 .ENTRY MAIN_LEVEL,0 MOVAB EXCEPTION_HANDLER,(FP) PUSHAL MSG0 CALLS #1,G^LIB$PUT_OUTPUT CALLS #0,FIRST_LEVEL PUSHAL MSG0 CALLS #1,G^LIB$PUT_OUTPUT RET .ENTRY FIRST_LEVEL,0 PUSHAL MSG1 CALLS #1,G^LIB$PUT_OUTPUT CALLS #0,SECOND_LEVEL PUSHAL MSG1 CALLS #1,G^LIB$PUT_OUTPUT RET .ENTRY SECOND_LEVEL,0 PUSHAL MSG2 CALLS #1,G^LIB$PUT_OUTPUT DECL COUNT BEQL 10$ PUSHL #12 CALLS #1,LIB$SIGNAL10$: PUSHAL MSG3 CALLS #1,G^LIB$PUT_OUTPUT RET;++:; The real crux of this demonstration program begins here.;--  .LIBRARY "SYS$SHARE:LIB.MLB"2 $CHFDEF ; condition handler facility definitions3 $CHFCTXDEF ; condition handler context definitions, $PDSCDEF ; procedure descriptor definitions6 $EVAX_INSTRDEF ; Alpha instruction format definitions7 $EVX_OPCODESDEF ; Alpha instruction opcode definitions;++I; The following condition handler demonstrates how to return to the firstI; instruction of the routine which incurred the exception to continue its ; processing.;H; This is accomplished by obtaining the frame pointer of the frame whichH; has incurred the exception from the condition handler facility contextI; area is on the stack above the mechanism array. The routine invocationI; handle is created from the exception frame pointer. The target programH; counter is obtained from the procedure's entry address in its PDSC andI; then, walking through the prologue's code until the instruction making H; the procedure the current procedure is located. The targetted program:; counter is the address of the instruction which follows.;--* .ENTRY EXCEPTION_HANDLER,^m8 MOVL CHF$L_MCHARGLST(AP),R0 ; get adr of machine array< MOVAL -CHFCTX$S_CHFCTXDEF(R0),R0 ; get adr of context array6 PUSHL CHFCTX$Q_EXPT_FP(R0) ; get exception frame ptr+ MOVL @(SP),R0 ; get exception frame PDSC6 MOVL PDSC$Q_ENTRY(R0),R0 ; get exception frame entry;++J; The instruction which makes the procedure current is a 'MOV SP,FP' which*; is implemented with a 'BIS R31,R30,R29'.;--@INSTR = !- ; BIS is a logical opcode8 !- ; the function is: BIS$ !- ; Ra = R31- !- ; Rb = R30 ; the SP+ ; Rc = R29 ; the FP 510$: CMPL (R0)+,#INSTR ; is this the BIS R31,SP,FP?) BNEQ 10$ ; no. check next instruction0 ASHL #1,(SP),(SP) ; compose invocation handle/ BISL2 #^x1F,(SP) ; for the exception frame& PUSHL R0 ; push target PC on stack+ MOVAL (SP),R0 ; save target's stack adr0 $GOTO_UNWIND_S TARGET_INVO=4(R0),TARGET_PC=(R0) RET .END MAIN_LEVEL*[DECUS.GOTOUNWIND]DESCRIP.MMS;1+,-./ 4/-)0123KPWO56[m74D`ou89GHJ EXE = .EXE MAR = .MAR OBJ = .OBJMAIN1 = DEMO_1MAIN2 = DEMO_2NOOPT = /NOOPTIMIZEDEBUG = /DEBUG/MFLAGS = $(MFLAGS)/LIST/MACHINE$(DEBUG)$(NOOPT)%LINKFLAGS = $(LINKFLAGS)/MAP$(DEBUG) *GOTOUNWIND : $(MAIN1)$(EXE),$(MAIN2)$(EXE)$(MAIN1)$(EXE) : $(MAIN1)$(OBJ)* $(LINK)$(LINKFLAGS) $(MMS$SOURCE_LIST)$(MAIN1)$(OBJ) : $(MAIN1)$(MAR)$(MAIN2)$(EXE) : $(MAIN2)$(OBJ)* $(LINK)$(LINKFLAGS) $(MMS$SOURCE_LIST)$(MAIN2)$(OBJ) : $(MAIN2)$(MAR)5 TMESIS.BCK. [DECUS]PERMANENT.DIR;1Ã*[DECUS]PERMANENT.DIR;1+,../ 4- 0123 KPWO56ޣ27Xߣ289GHJI$$$ABOUT.PERMANENT/ BUILD.COM0"BUILD_SYLOGIN_ONLY.COM1"INSTALL_PERMANENT.COM2 PERMANENT.MAR3 PERMANENT.RNH4%*[DECUS.PERMANENT]$$$ABOUT.PERMANENT;1+,/./ 4KH-.0123KPWO56jw⦗7FZ7[89GHJ9Copyright by Brian Schenkenberger and TMESIS ConsultingK All rights reserved. 1 -------------------------KThis software is provided "as is" and is supplied for informational purposeKonly. No warranty is expressed or implied and no liability can be acceptedKfor any actions or circumstances incurred from the use of this software or Kfrom the information contained herein. The author makes no claim as to theKsuitability or fitness of this software or information contain herein for aparticular purpose.1 -------------------------KThis software may be copied and distributed only with the inclusion of thiscopyright notice.J -------------------------------------------------------------------------6 * * * P E R M A N E N T * * * 1 ------------------------- Description: -----------HPERMANENT provides the ability to define a DCL string symbol pemanently.GPermanent DCL symbols can not be deleted with the DELETE/SYMBOL command not can they can be redefined. HPERMANENT can be used by system managers that wish to define system-wideHsymbols for all users and ensure that the symbols can no be deleted fromHthe process's symbol table. Optionally, the use of PERMANENT can be re-Hstricted to use in the SYLOGIN.COM file permitting the system manager to@define permanent symbols without giving the capability to users.7PERMANENT will run on both OpenVMS/VAX and OpenVMS/AXP.J -------------------------------------------------------------------------Release Information:------------------->This is the first release of the PERMANENT package. (v1.4%047)J -------------------------------------------------------------------------Distribution Information:------------------------JPERMANENT requires CMEXEC privilege and executes code at exec mode access.BTherefore, PERMANENT is distributed in source form for inspection..*** This package contains the following files:- -----------------------------------------KBUILD.COM .............. Compile and link source. Create .HLP source file.KBUILD_SYLOGIN_ONLY.COM . Compile and link source with optional restriction.JINSTALL_PERMANENT.COM .. Command file to install PERMANENT during startup.KPERMANENT.RNH .......... Digital Standard Runoff(DSR) source for .HLP file..PERMANENT.MAR .......... Source for PERMANENT.J*** BUILD.COM (or BUILD_SYLOGIN_ONLY.COM) will create the following files:I ---------------------------------------------------------------------@PERMANENT.HLB ......... OpenVMS help library file for PERMANENT.GPERMANENT.HLP ......... OpenVMS help library source file for PERMANENT.HPERMANENT.LIS ......... OpenVMS VAX/AXP listing file from PERMANENT.MAR.GPERMANENT.OBJ ......... OpenVMS VAX/AXP object file from PERMANENT.MAR.FPERMANENT.EXE ......... OpenVMS VAX/AXP executable file for PERMANENT.FPERMANENT.MAP ......... OpenVMS VAX/AXP linker map file for PERMANENT.J -------------------------------------------------------------------------G * * * I N S T A L L A T I O N O F P E R M A N E N T * * * EExecute the command procedure BUILD.COM (or BUILD_SYLOGIN_ONLY.COM ifFyou wish to restrict the capabilities of PERMANENT to use during loginto the SYLOGIN.COM file.) CThis will create the executable (PERMANENT.EXE) and the help files $(PERMANENT.HLP and PERMANENT.HLB). BOptionally, the .LISting and .MAP files can be disabled by passingCqualifiers to the BUILD.COM procedure. The first parameter should Cspecify a blank or valid optional MACRO qualifiers. To 'turn-off' Dthe generation of the .LISting file, specify "/NOLIST" as the first Bparameter. The second parameter is used to pass LINK qualifiers. DThe parameter should specify valid optional LINKing qualifiers. To C'turn-off' the generation of the .MAP file, specify "/NOMAP" as the!second parameter. For example: $ @BUILD "/NOLIST" "/NOMAP" -or-($ @BUILD_SYLOGIN_ONLY "/NOLIST" "/NOMAP"To generate just a MAP file:$ @BUILD "/NOLIST" "/MAP" -or-&$ @BUILD_SYLOGIN_ONLY "/NOLIST" "/MAP"CThe logical BUILD_VERIFY may be defined to a value of 1 to turn on ,command verification of the build procedure.-----BPERMANENT.EXE should be placed in SYS$COMMON:[SYSEXE] -- However, Dit is not required. If you choose, PERMANENT may be placed anywhereFon your system provided that the following logical definition is made.CThis line should be placed in SYLOGICALS.COM or your system startupprior to installing PERMANENT.G$ DEFINE/SYSTEM/EXECUTIVE PERMANENT $DEV$???:[]PERMANENT.EXE-----EPERMANENT must then be installed. This command line should be placedDin your system startup and should be activated after the logical (ifCPERMANENT.EXE was not placed in SYS$COMMON:[SYSEXE]) PERMANENT has 4been defined. Install PERMANENT with the following:E$ INSTALL ADD/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMEXEC PERMANENT-----EThe above two steps can be performed using the INSTALL_PERMANENT.COM Dprocedure. Invoke the INSTALL_PERMANENT.COM procedure during systemDstartup. If PEMANENT is not placed in SYS$COMMON:[SYSEXE], pass the=file specification to the INSTALL_PERMANENT.COM procedure. BFor example, the following is placed in SYSTARTUP_V5.COM (or V6.n:CSYSTARTUP_VMS.COM) to install PERMANENT. Assume, for this example,Bthat the system mananger has placed PERMANENT.EXE in the directory(SYS$SYSDEVICE:[PUBLIC_DOMAIN.PERMANENT].H$ @SYS$STARTUP:INSTALL_PERMANENT SYS$SYSDEVICE:[PUBLIC_DOMAIN.PERMANENT]-----CTo make the command available, define the foreign command PERMANENTusing the following syntax:$ PERMANENT :== $PERMANENTAThis should be placed in SYLOGIN.COM to make it available for allusers.DThis program requires CMEXEC privilege. It is installed with CMEXEC.privilege by the INSTALL_SYMBOL.COM procedure.GIf PERMANENT is built with the option to restrict its use to the systemGSYLOGIN.COM file, the system logcial SYS$SYLOGIN must be defined and itGmust point to the location of the SYLOGIN.COM file which is executed. -----DPERMANENT help functions can be provided using one of the following:EThe PERMANENT help information can be added directly to the existing CVMS help library. The PERMANENT.HLP source file is created by the DBUILD.COM (or BUILD_SYLOGIN_ONLY.COM) procedure. This file is used Cto update the default VMS help library using the following comma TMESIS.BCK/.%[DECUS.PERMANENT]$$$ABOUT.PERMANENT;1KDnd:9$ LIBRARY/HELP/INSERT SYS$HELP:HELPLIB.HLB PERMANENT.HLP - or -CPERMANENT help information can be provided by defining an optional @default library logical (HLP$LIBRARY_xxx) which should translateto PERMANENT.HLB.E$ DEFINE/SYSTEM/EXECUTIVE HLP$LIBRARY_x $DEV$???:[]PERMANENT.HLB-----.END.*[DECUS.PERMANENT]BUILD.COM;1+,0./ 4u-.0123KPWO56z⦗77[89GHJ$! Copyright 1994 by Brian Schenkenberger and TMESIS Consulting $!-------------------------------------------------------------------------- $! Define the logical BUILD_VERIFY to 1 to enable procedure verification $! Parameter P1 = any valid MACRO qualifiers (enclosed in quotataion marks) $! Parameter P2 = any valid LINK qualifiers (enclosed in quotataion marks) $! To specify LINK only qualifiers, specify P1 as a null string (""). $!-------------------------------------------------------------------------- $ SET := SET ! make sure SET *is* SET $ $ SET ON ! enable error checking $ ON ERROR THEN $ GOTO EXIT_RTN ! establish error handler $ ON CONTROL_Y THEN $ GOTO EXIT_RTN ! establish ctrl-Y handler $ $ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs $ $ DEFINE/USER SAVE_VERIFY "''F$INT(F$ENV("VERIFY_PROCEDURE")),''F$INT(F$ENV("VERIFY_IMAGE"))'" $ $ RUNOFF PERMANENT.RNH ! format the .HLP source file 'F$verify(F$trnlnm("BUILD_VERIFY"),0) $ $ EDIT/TECO/EXECUTE=SYS$INPUT ! convert .HLP to variable, CR-CC file EBPERMANENT.HLPEGPU *.HLP $ $ LIBRARY/CREATE=BLOCKS:0/HELP PERMANENT.HLB PERMANENT.HLP ! create helplib $ $ MACRO/LIST'P1' PERMANENT.MAR $ $ IF "''F$trnlnm("ALPHA$LOADABLE_IMAGES","LNM$SYSTEM_TABLE",,,,"VALUE")'".EQS."" !'F$verify(F$trnlnm("SAVE_VERIFY")) $ THEN $ On_VAX: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ LINKNOTRACEBACK/MAP'P2' PERMANENT.OBJ,SYS$INPUT/OPT ! create .EXE SYS$SYSTEM:SYS.STB/SELECTIVE_SEARCH SYS$SYSTEM:DCLDEF.STB/SELECTIVE_SEARCH GSMATCH=EQUAL,1,%x40051 ! makes GS id reflect version $ ELSE !'F$verify(F$trnlnm("SAVE_VERIFY")) $ On_AXP: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ LINK/SYSEXE/NOTRACEBACK/MAP'P2' PERMANENT.OBJ,SYS$INPUT/OPT ! create .EXE ALPHA$LOADABLE_IMAGES:DCLDEF.STB/SELECTIVE_SEARCH GSMATCH=EQUAL,1,%x40051 ! makes GS id reflect version $ ENDIF !'F$verify(F$trnlnm("SAVE_VERIFY")) $ EXIT_RTN: EXIT $STATUS !'F$verify(F$trnlnm("SAVE_VERIFY")) )*[DECUS.PERMANENT]BUILD_SYLOGIN_ONLY.COM;1+,1./ 4uB-.0123KPWO56bl78[89GHJ A$! Copyright 1994 by Brian Schenkenberger and TMESIS ConsultingL$!--------------------------------------------------------------------------H$! Define the logical BUILD_VERIFY to 1 to enable procedure verificationK$! Parameter P1 = any valid MACRO qualifiers (enclosed in quotataion marks)J$! Parameter P2 = any valid LINK qualifiers (enclosed in quotataion marks)G$! To specify LINK only qualifiers, specify P1 as a null string (""). L$!--------------------------------------------------------------------------($ SET := SET ! make sure SET *is* SET$#$ SET ON ! enable error checking:$ ON ERROR THEN $ GOTO EXIT_RTN ! establish error handler>$ ON CONTROL_Y THEN $ GOTO EXIT_RTN ! establish ctrl-Y handler$@$ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs$^$ DEFINE/USER SAVE_VERIFY "''F$INT(F$ENV("VERIFY_PROCEDURE")),''F$INT(F$ENV("VERIFY_IMAGE"))'"$o$ RUNOFF PERMANENT.RNH/VARIANT=SYLOGINONLY ! format the .HLP source file 'F$verify(F$trnlnm("BUILD_VERIFY"),0)$E$ EDIT/TECO/EXECUTE=SYS$INPUT ! convert .HLP to variable, CR-CC fileEBPERMANENT.HLPEGPU *.HLP$K$ LIBRARY/CREATE=BLOCKS:0/HELP PERMANENT.HLB PERMANENT.HLP ! create helplib$G$ EDIT/SUM PERMANENT.MAR/OUTPUT=PERMANENT.MAR_RESTRICT/UPDATE=SYS$INPUT-2SELECT_SYLOGIN_ONLY_USAGE=1 ; Option: PERMANENT restricted to SYLOGIN.COM file usageB .PRINT 0 ;PERMANENT will be restricted to SYLOGIN.COM file usage./$'$ MACRO/LIST'P1' PERMANENT.MAR_RESTRICT$u$ IF "''F$trnlnm("ALPHA$LOADABLE_IMAGES","LNM$SYSTEM_TABLE",,,,"VALUE")'".EQS."" !'F$verify(F$trnlnm("SAVE_VERIFY"))$ THENP$ On_VAX: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY"))E$ LINK/NOTRACEBACK/MAP'P2' PERMANENT.OBJ,SYS$INPUT/OPT ! create .EXE% SYS$SYSTEM:SYS.STB/SELECTIVE_SEARCH( SYS$SYSTEM:DCLDEF.STB/SELECTIVE_SEARCH9 GSMATCH=EQUAL,1,%x40051 ! makes GS id reflect version4$ ELSE !'F$verify(F$trnlnm("SAVE_VERIFY"))P$ On_AXP: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY"))L$ LINK/SYSEXE/NOTRACEBACK/MAP'P2' PERMANENT.OBJ,SYS$INPUT/OPT ! create .EXE3 ALPHA$LOADABLE_IMAGES:DCLDEF.STB/SELECTIVE_SEARCH9 GSMATCH=EQUAL,1,%x40051 ! makes GS id reflect version5$ ENDIF !'F$verify(F$trnlnm("SAVE_VERIFY"))<$ EXIT_RTN: EXIT $STATUS !'F$verify(F$trnlnm("SAVE_VERIFY"))(*[DECUS.PERMANENT]INSTALL_PERMANENT.COM;1+,2./ 4K-.0123KPWO56a⦗7P8[89GHJA$! Copyright 1994 by Brian Schenkenberger and TMESIS ConsultingJ$!------------------------------------------------------------------------K$! This file should be executed during system startup to install PERMANENT.J$! If PERMANENT was not placed in the directory: SYS$COMMON:[SYSEXE] then,J$! pass the device and directory specification where PERMANENT.EXE resides%$! as a parameter to this procedure. J$!------------------------------------------------------------------------3$ IF "''P1'" .EQS "" THEN $ P1:=SYS$COMMON:[SYSEXE]D$ DEFINE/SYSTEM/EXECUTIVE PERMANENT "''F$parse("PERMANENT.EXE",P1)'"E$ INSTALL REPLACE/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMEXEC/LOG - 'F$parse("PERMANENT.EXE",P1)'$ EXIT *[DECUS.PERMANENT]PERMANENT.MAR;1+,3./ 4M -.0123KPWO56h7\L8[89GHJ* .TITLE PERM ; define a symbol permanent4 .IDENT "PERM V1%4.051" ; internals demo program...;++J; This program will establish a permanent symbol definition for the symbol3; specified as the input parameter to this program.I; This program can be used to make any defined "STRING" symbol permanent.;--L; Copyright 1994 by Brian Schenkenberger and TMESIS Consulting, Jackson NJM; All rights reserved. 3; ----------HO TMESIS.BCK3. [DECUS.PERMANENT]PERMANENT.MAR;1M---------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.3; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; OpenVMS/VAX Build:;; $ MACRO PERMANENT; $ LINK PERMANENT;--; OpenVMS/AXP Build:;; $ MACRO PERMANENT8; $ LINK/SYSEXE PERMANENT,SYS$LOADABLE_IMAGES:DCLDEF.STB;--(; PERMANENT requires CMEXEC privilege. ;-- ; To use: 7; 1) First, define a foreign command symbol definition:0; $ PERMANENT:==$DISK$???:[]PERMANENT;2; 2) Then, define the symbol to be made permanent:4; $ ETERNITY:=="I want this symbol to live forever!";@; 3) Use the command PERMANENT to define the symbol permanently.; $ PERMANENT ETERNITY; E; 4) Any attempt to redefine the symbol will result in the following:;; %DCL-W-PERMSYM, deletion of permanent symbols not allowed;--; Modifications:; 09-FEB-1994: creation date.;-- .NTYPE ...ON_ALPHA...,R315 .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, .DISABLE FLAGGING; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly( $LIBCLIDEF ; LIB${GET/SET}_SYMBOL codes% $CLIMSGDEF ; CLI error message codes+ $DSCDEF ; VMS descriptor class/type codesM;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,QUAD5SYMBOL: .LONG !,0ARGLST: .LONG 1 .ADDRESS SYMBOLEAUTODIN:.LONG ^x00000000,^x1DB71064 ; Autodin-II CRC polynomial table> .LONG ^x3B6E20C8,^x26D930AC ; -------------------------------? .LONG ^x76DC4190,^x6B6B51F4 ; used to calculate a hash value? .LONG ^x4DB26158,^x5005713C ; of the symbol to determine the@ .LONG ^xEDB88320,^xF00F9344 ; index of the symbol table list-? .LONG ^xD6D6A3E8,^xCB61B38C ; head where the symbol's (SYM) = .LONG ^x9B64C2B0,^x86D3D2D4 ; block will/should be queued.> .LONG ^xA00AE278,^xBDBDF21C ; -------------------------------D .IF DF ELECT_SYLOGIN_ONLY_USAGE ;++ Optional restriction check code( $LNMDEF ; TRNLNM item list definitionsLNMITEMS: .WORD 255,LNM$_STRING .ADDRESS SYLOGIN .ADDRESS SYLOGLEN .LONG 0SYLOGIN: .BLKB 256SYLOGLEN: .LONG 0*FAB: $FAB FNA=SYLOGIN,NAM=NAM,DNM=<.COM;>&NAM: $NAM ESA=EXPAND,ESS=NAM$C_MAXRSSEXPAND: .BLKB NAM$C_MAXRSS&LNM$SYS_TAB: .ASCID /LNM$SYSTEM_TABLE/!SYS$SYLOGIN: .ASCID /SYS$SYLOGIN/- .ENDC ;-- Optional restriction check codeM;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,QUAD .ENTRY PERM_SYM,^m<>D .IF DF ELECT_SYLOGIN_ONLY_USAGE ;++ Optional restriction check code= $TRNLNM_S TABNAM=LNM$SYS_TAB,- ; search system logical table4 LOGNAM=SYS$SYLOGIN,- ; for SYS$SYLOGIN and return* ITMLST=LNMITEMS ; its translated value BLBS R0,10$ RETB10$: MOVB SYLOGLEN,FAB+FAB$B_FNS ; update FAB with filename length. $PARSE FAB=FAB ; parse to get expanded name BLBS R0,20$ RET120$: $SEARCH FAB=FAB ; search to get exact name BLBS R0,30$ RET- .ENDC ;-- Optional restriction check code230$: PUSHAB SYMBOL ; get the name of the symbol4 CALLS #1,G^LIB$GET_FOREIGN ; from the command line BLBS R0,40$ RET<40$: $CMEXEC_S ROUTIN=SET_PERM,- ;call SET_PERM at exec mode ARGLST=ARGLST RET;++L; This routine calculates and locates the listhead in which the symbol's SYML; block should be located. It then walks-the-list looking for the specified=; symbol. When it is located, it sets the type to PERManent.;--' .ENTRY SET_PERM,^m 7 MOVAB @#CTL$AG_CLIDATA,R7 ; base of cli data regionD .IF DF ELECT_SYLOGIN_ONLY_USAGE ;++ Optional restriction check code- MOVL PPD$L_PRC(R7),R0 ; get adr of prc area4 MOVL PRC_L_IDFLNK(R0),R1 ; get the first IDF block4 MOVL IDF_L_FILENAME(R1),R2 ; and find the filename3 MOVZBL NAM+NAM$B_ESL,R0 ; length of expanded name2 MOVL NAM+NAM$L_ESA,R1 ; address of expanded name 4 CMPC3 R0,(R1),1(R2) ; compare it with SYS$SYLOGIN& BEQL 10$ ; continue if it compares) MOVL #SS$_NOPRIV,R0 ; tell user NOPRIV RET- .ENDC ;-- Optional restriction check code+10$: MOVQ @4(AP),R4 ; get the symbol name0 CRC AUTODIN,#-1,R4,(R5) ; calc the hash value - BICL2 #^C^XFF,R0 ; calc the listhead index= MOVAQ @PPD$Q_CLISYMTBL+4(R7)[R0],R6 ; get the assoc listhead+ MOVL R6,R7 ; save for end-of-line check220$: MOVL (R6),R6 ; walk the list of SYM blocks# CMPL R7,R6 ; end of the line??? BEQL 30$ ; quit if at end.5 MOVAB SYM_T_SYMBOL(R6),R1 ; get ascic symbol adress' MOVZBL (R1)+,R0 ; extract the length0 CMPC5 R0,(R1),#0,R4,(R5) ; is this our symbol?& BNEQ 20$ ; better luck next round.2 TSTW SYM_W_NONUNIQUE(R6) ; is the symbol unique?& BLSS 20$ ; branch if not unique... 4 TSTW SYM_W_PROCLEVEL(R6) ; is it a gbl/lcl symbol? BGEQ 20$ ; local symbol test= CMPB #SYM_K_STRING,SYM_B_TYPE(R6) ; is this a string symbol? BNEQ 30$4 MOVB #SYM_K_PERM,SYM_B_TYPE(R6) ; make it permanent( MOVL #CLI$_NORMAL,R0 ; signal success RET030$: MOVL #CLI$_UNDSYM,R0 ; return with UNDSYM RET .END PERM_SYM *[DECUS.PERMANENT]PERMANENT.RNH;1+,4./ 4H-.0123KPWO56⦗78[89GHJ.nfl accept .nfl bold .fl space .lm 0 .rm 78 !Copyright 1994 by Brian Schenkenberger and TMESIS Consulting .rm 72 .br .b 1 PERMANENT .lm 1 .br PERMANENT provides the ability to define a DCL string symbol pemanently. Permanent DCL symbols can not be deleted with the DELETE/SYMBOL command nor can they can be redefined. .IF SYLOGINONLY .b PERMANENT is restricted to use in the SYLOGIN.COM file only. The system manager can use PERMANENT to define system-wide symbols which can not be deleted from the user's symbol table. .ENDIF SYLOGINONLY .b Format .b .lm 3 PERMANENT##parameter .lm 0 .rm 70 .br 2 Parameter .lm 1 .br The PERMANENT command requires one parameter, the name of the symbol to be made a permanent symbol in the user's symbol table. .lm 0 .rm 70 .br 2 Examples .lm 1 .b .lm 1 1.#$#ZEIT#==#"SHOW#TIME" .break ###$#PERMANENT#ZEIT .b The PERMANENT command in this example will make the symbol definition for the symbol ZEIT a permanent symbol. Any attempt to delete or redefine the symbol will not succee TMESIS.BCK4. [DECUS.PERMANENT]PERMANENT.RNH;1Hhd. .lm 0 .rm 70 .br .br 2 Version .lm 1 .br PERMANENT#version#V1%4.051 .br Copyright##1994#by#Brian#Schenkenberger#and#TMESIS#Consulting *[DECUS]REPEAT.DIR;1+,5./ 4- 0123 KPWO56H27/[289GHJI $$$README.TXT6 DESCRIP.MMS7REPEAT$CMD.MAR8 REPEAT.CLD9*[DECUS.REPEAT]$$$README.TXT;1+,6./ 4O-50123KPWO567EC/7C/89GHJ O.-----------------------------------------------------------------------------.O| Copyright 1992, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED. |O| |O| This software is provided "AS IS" and is supplied for informational purpose |O| only. No warranty is expressed or implied and no liability can be accepted |O| for any actions or circumstances incurred from the use of this software or |O| from the information contained herein. The author makes no claim as to the |O| suitablility or fitness of the software or information contain herein for a |O| particular purpose. |O| |O| Permission is hereby granted _ONLY_ for the "not-for-profit" redistribution |O| of this software provided that ALL SOURCE and/or OBJECT CODE remains intact |O| and ALL COPYRIGHT NOTICES remain intact from its original distribution. |O| |O|(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!) |O`-----------------------------------------------------------------------------'Package name: REPEAT GDescription: An amuzing little ditty that I whipped up several years9 ago. This package creates a DCL command which will, in: turn, allow the user to invoke a DCL command repeatedly.: It was originally submitted to "Digital Systems Journal": for use as a "technical tip" filler but was never placed in print in the journal. $Author's name: Brian SchenkenbergerPackage Overview:----------------BPete and Repeat stood at a cliff. Pete jumped off. Who was left?HFor children, the answer provides a source of amusement. For the SystemIManager, the answer is a monitoring tool which can be used for collectionof system statistics.IOpenVMS is replete with myriad examples of this. The monitor utility andJthe DCL commands: "SHOW PROCESS/CONTINUOUS" and "SHOW CLUSTER/CONTINUOUS".IHow many times have you wished that all the utilities or DCL commands hadJthis capability? How many times have you used the UP arrow recall and theIENTER key or written a DCL command procedure loop to repeat some command?JNo more!!! REPEAT will allow you to repeat a DCL command on a one second +interval as a simple DCL command: $ REPEAT.*[DECUS.REPEAT]DESCRIP.MMS;1+,7./ 43X-50123KPWO56(7 Q-89GHJ##NOOPT = /NOOPTIMIZE##DEBUG = /DEBUG/MFLAGS = $(MFLAGS)/LIST/MACHINE$(DEBUG)$(NOOPT)%LINKFLAGS = $(LINKFLAGS)/MAP$(DEBUG) .IFDEF __ALPHA__SYSEXE = /SYSEXE.ELSESYSEXE = ,SYS$SYSTEM:SYS.STB.ENDIFREPEAT$CMD.EXE : REPEAT$CMD.OBJ3 $(LINK)$(LINKFLAGS) $(MMS$SOURCE_LIST)$(SYSEXE)REPEAT$CMD.OBJ : REPEAT$CMD.MAR*[DECUS.REPEAT]REPEAT$CMD.MAR;1+,8. / 4M -50123KPWO 56";0C/72C/89GHJ ;++G; Copyright 1992, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--8 .TITLE REPEAT$CMD ; just another amusing OpenVMS toy  .IDENT "V1.0%6.063" .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGING .LIBRARY "SYS$LIBRARY:LIB"* $CLIDEF ; DCL CLI Dispatcher Definitions/ $CLISERVDEF ; DCL CLI Service Code Definitions- $DSCDEF ; Descriptor Type/Class Definitions- $PCBDEF ; Process Control Block Definitions;++; REPEAT program data section;-- .PSECT REPEAT$DATA,WRT,NOEXE,5 ;S mS uS TC=100nS$ONE.SECOND: .LONG -1*1000*1000*10,-1?CMD$REPEAT: .LONG !,0GET$COMMAND: .LONG 3 .ADDRESS DCL$COMMAND .ADDRESS CMD$REPEAT .ADDRESS CMD$REPEAT!PROGRAM_NAME: .ASCIC /REPEAT$CMD/ .ALIGN LONG"DCL$COMMAND: .ASCID /COMMAND_LINE/;++; REPEAT program code section;-- .PSECT REPEAT$CODE,NOWRT,EXE,5 .ENTRY REPEAT$COMMAND,07 MOVAB DISMISS_SIGNAL,(FP) ; make CLI not signal error> CALLG GET$COMMAND,G^CLI$GET_VALUE ; get repeat command stream, CLRL (FP) ; let signalled errors thru BLBC R0,20$) PUSHL G^CTL$AG_CLITABLE ; use DCLTABLES( PUSHAL CMD$REPEAT ; command to repeat6 CALLS #2,G^CLI$DCL_PARSE ; parse command for syntax. BLBS R0,10$ RET910$: $CMEXEC_S ROUTIN=COPY_TO_COMMON ; save command line  BLBS R0,30$ RET;++M; The following 2 lines add a 1 sec. delay while displaying the command to beL; repeated. This serves a two fold purpose: First, it allows the user some K; time to view the output of the command being repeated; second, it allowsK; the user to abort the command. Explaination. A control-Y delivered whileJ; the repeated command@ TMESIS.BCK85[DECUS.REPEAT]REPEAT$CMD.MAR;1M }  image is active will ONLY abort the repeated image,K; and not stop the repetition of the command (ie. this program chained ontoK; the end of the previous image. While the program is in the LEF state, a-J; waiting the 1 second to expire, the user may issue a control-Y to abort K; the repeat command. Removing this delay, the program re-queues the imageK; to be repeated and the chaining of this program to quickly to ensure that!; the user can abort the command.;-- 20$: $SCHDWK_S DAYTIM=ONE.SECOND $HIBER_S .30$: CLRQ -(SP) ; make room for cli service' CLRQ -(SP) ; dispatch data block( MOVL SP,R9 ; DCL wants address in r9: MOVZBL #CLI$K_CLISERV,CLI$B_RQTYPE(R9) ; set up the CLI's7 MOVW #CLI$K_COMMAND,CLI$W_SERVCOD(R9); dispatcher data MOVAB @#CTL$A_COMMON,R00 MOVZBW (R0)+,CLI$W_RQSIZE(R9) ; block to issue, MOVAB (R0),CLI$A_RQADDR(R9) ; a command...5 CHMS CLI$W_SERVCOD(R9) ; dispatch requested service8 MOVB #CLI$K_CLISERV,CLI$B_RQTYPE(R9) ; set up the CLI's6 MOVW #CLI$K_CHAIN,CLI$W_SERVCOD(R9) ; dispatcher data8 MOVZBW PROGRAM_NAME,CLI$W_RQSIZE(R9) ; block to run the: MOVAB PROGRAM_NAME+1,CLI$A_RQADDR(R9) ; repeat program...5 CHMS CLI$W_SERVCOD(R9) ; dispatch requested service$ RET ; all done...meet yer maker;++L; This routine is dispatched by the condition handling mechanism of OpenVMS.E; It is used to suppress signalled error conditions in the procedure.;- .ENTRY DISMISS_SIGNAL,0 MOVL #1,R0 RET;++I; This routine executes at executive access mode, allowing writes to the G; common area defined by CTL$A_COMMON. This address is located in the J; user's P1 space with page protection of UREW; thus, requiring a minimum 4; of executive mode access to modify the data area. ;F; This routine first checks to see that the process is an interactive E; process and returns with error IVMODE if not interactive. This isI; to avoid problems of this command being used in non-interactive mode. ;-- .ENTRY COPY_TO_COMMON,0> BBS #PCB$V_INTER,PCB$L_STS(R4),10$ ; check current proc. mode MOVL #SS$_IVMODE,R0 RET10$: MOVAB @#CTL$A_COMMON,R0 MOVB CMD$REPEAT,(R0)+$ MOVC3 CMD$REPEAT,@CMD$REPEAT+4,(R0) MOVL #1,R0 RET .END REPEAT$COMMAND*[DECUS.REPEAT]REPEAT.CLD;1+,9./ 4M-50123KPWO56XC/7\C/89GHJ!++M! Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.!M! This software is provided "AS IS" and is supplied for informational purposeM! only. No warranty is expressed or implied and no liability can be acceptedM! for any actions or circumstances incurred from the use of this software or M! from the information contained herein. The author makes no claim as to theM! suitablility or fitness of the software or information contain herein for a! particular purpose.!M! Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM! of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK! and ALL COPYRIGHT NOTICES remain intact from its original distribution. !M!(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!)!--DEFINE VERB REPEAT IMAGE REPEAT$CMD PARAMETER P1, PROMPT="Command", LABEL=COMMAND_LINE,% VALUE(REQUIRED,TYPE=$REST_OF_LINE)*[DECUS]SSINT.DIR;1+,:./ 4- 0123 KPWO56hr27H289GHJI $$$README.TXT; BUILD.COM< DESCRIP.MMS=SSDOINIHACK.MAR>SSINTERCEPT.MAR?SSINTERCEPT.OPT@SSINTLOADER.MARA _CLEAN.COMB*[DECUS.SSINT]$$$README.TXT;1+,;. / 4O -:0123KPWO 56[B#w.7K%w.89GHJ O.-----------------------------------------------------------------------------.O| Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED. |O| |O| This software is provided "AS IS" and is supplied for informational purpose |O| only. No warranty is expressed or implied and no liability can be accepted |O| for any actions or circumstances incurred from the use of this software or |O| from the information contained herein. The author makes no claim as to the |O| suitablility or fitness of the software or information contain herein for a |O| particular purpose. |O| |O| Permission is hereby granted *ONLY* for the "not-for-profit" redistribution |O| of this software provided that ALL SOURCE and/or OBJECT CODE remains intact |O| and ALL COPYRIGHT NOTICES remain intact from its original distribution. |O| |O|(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!) |O`-----------------------------------------------------------------------------'.Package name: SSINT (System Service INTercept)EDescription: Demonstration of interception of system service routines; on OpenVMS Alpha via a loadable executive image(execlet).$Author's name: Brian SchenkenbergerPackage Overview:----------------GThis package is comprised of a single loadable executive image(execlet)Gwhich demonstrates a method for intercepting a system service's serviceGroutine on OpenVMS Alpha. For demonstration purposes, this incarnationGof SSINT intercepts the system service SYS$CREPRC and outputs a messageGon the system console device whenever the service is invoked to displayGthe PID of the process invoking the service and the status of the call.FThis execlet is unique in that, it does not declare its initializationFroutines in the normal fashion using the INITIALIZATION_ROUTINE macro.FNormally, an initialization routine would be declared using this macroGwhich, in turn, builds the table of vectors of initialization routines.FThis table is then used by the INI$DOINIT routine in module SYS$DOINITFto call the execlet's initialization routines. Unfortunately, this isFnot an appropriate initialization senario in cases where an execlet isGrequired to perform some funct5 TMESIS.BCK;:[DECUS.SSINT]$$$README.TXT;1O uion prior to default functions performed +as a consequence of the INI$DOINIT routine. GIn this particular execlet, certain initialization functions need to beFperformed before the INI$DOINIT routine invokes the INI$SYSTEM_SERVICEHprocedure which, in turn, invokes the procedure EXE$CONNECT_SERVICES to /define the replacement system service function.GTo accomplish the requirements discussed above, a local routine called:FSSINT$DOINIT, is established for this execlets transfer address; thus,Fcausing the execlet loader to invoke IT for the initialization routine)instead of the normal INI$DOINIT routine.FAfter this initialization code in invoked, the INI$DOINIT routine mustFbe invoked. Unfortunately, this routine is not defined globally to beFcalled by another routine. Therefore, by playing a little "game" withFthe ordering of the initialization linkage, a symbol can be defined inFthe EXEC$INIT_LINKAGE psect to establish the location of the ProcedureFDeSCriptor (PDSC) of the INI$DOINIT routine. This is accomplished viathe module SSDOINIHACK.MAR.EThe initialization routine in this execlet is used to obtain the PDSCFaddress of the original service routine for the system service that isFbeing intercepted. A change mode system service which changed mode isFdefined by a bound procedure value procedure descriptor. The address Efound at PDSC$Q_ENTRY in the system service's procedure descriptor isFthe address of the system service transfer vector code. For a change Hmode system service, this vector will contain the following code thread:,SYS$_C+00: LDL R1,(SP) ; A03E0000/SYS$_C+04: BIS SP,R31,R28 ; 47DF041C8SYS$_C+08: LDA R0,#X(R31) ; 201Fxxxx3SYS$_C+0C: CHMx ; 0000008x (x: 2=E/3=K) F* Note: The format of the system service transfer vector under OpenVMSA Alpha version prior to V6.1 differ from the above and therefore,A this execlet will not function without making necessary changes.FThe initialization code looks through the vector to determine the modeEof the system service and the assigned change mode code of the systemFservice. After obtaining these values, the address of the change modeDdispatch vector is calculated and the service routine's PDSC addressFis stored for transfer to later in the intercept (replacement) system Eservice routine. The dispatch table entry vector format is depicted below.+-----+-----+-----+-----+H| DISP_A_SERVICE_ROUTINE|:CMOD$AR__DISPATCH_VECTOR+10(16)*chm-code+-----+-----+-----+-----+ | DISP_A_ENTRY_POINT |+-----+-----+-----+-----+ | |FLAGS|+-----+-----+-----+-----+ | |+-----+-----+-----+-----+ HThe module SSINTLOADER.MAR can be used to dynamically load the execlet. FThis execlet could also be loaded during system initialization. To doGthis, define the execlet using the SYSMAN command: SYS_LOADABLE ADD. FAn execlet must reside in SYS$LOADABLE_IMAGES to load it during systemFbootstrapping. After adding the execlet using SYSMAN, a DCL procedureDcalled VMS$SYSTEM_IMAGES.COM located in SYS$UPDATE must be executed..END.*[DECUS.SSINT]BUILD.COM;1+,<./ 4`-:0123KPWO56^789GHJN$!****************************************************************************N$! Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.$!N$! This software is provided "AS IS" and is supplied for informational purposeN$! only. No warranty is expressed or implied and no liability can be acceptedN$! for any actions or circumstances incurred from the use of this software or N$! from the information contained herein. The author makes no claim as to theN$! suitablility or fitness of the software or information contain herein for a$! particular purpose.$!N$! Permission is hereby granted *ONLY* for the "not-for-profit" redistributionN$! of this software provided that ALL SOURCE and/or OBJECT CODE remains intactL$! and ALL COPYRIGHT NOTICES remain intact from its original distribution. $!N$!(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!)N$!****************************************************************************$!++G$! SSINT's BUILD.COM file should be used when building on systems whichI$! are using Digital's MMS utility to define the macro __ALPHA__ which isG$! defined automatically when building with the Freeware MMK utility. $!J$! Also, although not currently available, if an Alpha implementation withJ$! with a page size greater than 8K is available, this procedure should beH$! used to determine the target Alpha's page size and build the loadable$! execlet accordingly.$!--=$ IF "''F$type(MMK)'".NES."" THEN $ MMS = 'MMK' ! MMS or MMKD$ IF "''F$extract(F$getsyi("HW_MODEL").GE.1024,3,"VAXP")'".EQS."VAX"$ THEN$ MMS$ ELSE`$ MMS/MACRO=(PAGESIZE='F$element(F$getsyi("PAGE_SIZE")/%x4000,"/","13/14/15//16"),__ALPHA__=1)$ ENDIF*[DECUS.SSINT]DESCRIP.MMS;1+,=./ 4O-:0123KPWO56D7]D89GHJI#########################################################################I## SSINIT: A Loadable Executive Image (LEI) example -- build file ##I#########################################################################.FIRST :O @ WRITEE SYS$OUTPUT "Copyright 1992, 1994, 1996 by Brian Schenkenberger.". @ WRITEE SYS$OUTPUT "ALL RIGHTS RESERVED."O @ WRITEE SYS$OUTPUT "-----------------------------------------------------" MAR = .MAR EXE = .EXE OBJ = .OBJ OPT = .OPT;.IFDEF __ALPHA__ ## qualifier macros for use on OpenVMS AXPPAGESIZE = 13MFLAGS = /LIST/MACHINE?LINKFLAGS = /MAP/FULL/NOTRACEBACK/NATIVE_ONLY/BPAGE=$(PAGESIZE)SYSEXE = /SYSEXE=SELECTIVE2.ELSE ## qualifier macros for use on OpenVMS VAXMFLAGS = /LIST!LINKFLAGS = /MAP/FULL/NOTRACEBACK(SYSEXE = ,SYS$SYSTEM:SYS.STB/SELECTIVE.ENDIF##0## Loadable Executive Image (LEI) is SSINTERCEPT## LEI = SSINTERCEPTDOX = SSDOINIHACKLDR = SSINTLOADER##/## SSINTERCEPT component dependency build rules##"$(LEI) : $(LEI)$(EXE),$(LDR)$(EXE)7 @ WRITE SYS$OUTPUT " - SSINTERCEPT build complete."5$(LEI)$(EXE) : $(LEI)$(OBJ),$(DOX)$(OBJ),$(LEI)$(OPT)9 - $(LINK)$(LINKFLAGS)/SHAREABLE/NOSYSSHR/SYMBOL_TABLE -> $(LEI)$(OBJ),$(DOX)$(OBJ)$(SYSEXE),$(LEI)$(OPT)/OPTION$(LDR)$(EXE) : $(LDR)$(OBJ). $(LINK)$(LINKFLAGS) $(MMS$SOURCE)$(SYSEXE)$(LEI)$(OBJ) : $(LEI)$(MAR)$(DOX)$(OBJ) : $(DOX)$(MAR)$(LDR)$(OBJ) : $(LDR)$(MAR)N|@ TMESIS.BCK>:[DECUS.SSINT]SSDOINIHACK.MAR;1M*[DECUS.SSINT]SSDOINIHACK.MAR;1+,>./ 4M~-:0123KPWO56@e|E78}E89GHJ;++M; Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--; .TITLE SSDOINIHACK ; template program demonstrating how to< .IDENT /V1.0 (demo)/ ; intercept a system service on Alpha.;++G; This module is used to define the beginning of the linkage section ofH; the SYS$DOINIT module. Because this module makes no contributions to G; the psect, the SYS$DOINIT module's linkage section will begin at the G; same location thus, permitting the label INI$DOINIT to represent the !; PDSC of the INI$DOINIT routine.;--C .PSECT EXEC$INIT_LINKAGE,5,PIC,CON,REL,LCL,NOSHR,EXE,RD,WRT INI$DOINIT:: .END*[DECUS.SSINT]SSINTERCEPT.MAR;1+,?./ 4Mf-:0123KPWO56EXK7K89GHJ;++M; Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--< .TITLE SSINTERCEPT ; template program demonstrating how to < .IDENT /V1.0 (demo)/ ; intercept a system service on Alpha.;++ ; Library and include requisites;--4 .LIBRARY "SYS$LIBRARY:STARLET.MLB" ; look here for:3 $EVX_OPCODESDEF ; Alpha (EVAX) opcodes definitions, $PDSCDEF ; procedure descriptor definitions+ $SSDEF ; system status & completion codes1 .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here for:, $DISPDEF ; dispatch table entry definitions0 $LDRIMGDEF ; loadable execlet image definitions0 $INIRTNDEF ; execlet initialization definitions;++H; The following includes are necessary for the particular mission of the0; interception of the SYS$CREPRC system service.;--- $PCBDEF ; process control block definitions;++E; The following macros are used to output information to the console.;-- .MACRO OUTPUT,MSGTEXT,?LBL .SAVE_PSECT LOCAL_BLOCK! DECLARE_PSECT EXEC$NONPAGED_DATA .ALIGN LONG5MSG'LBL:.ASCIC <13><10>"%SSintercept, MSGTEXT"<7><13> .ALIGN LONG .RESTORE_PSECT PUSHR #^m MOVL G^OPA$AR_UCB0,R5 MOVAB MSG'LBL,R2 MOVZBL (R2)+,R1 JSB G^IOC$BROADCAST POPR #^m .ENDM OUTPUT .MACRO OUTHEX,MSGTEXT,HEX,?LBL .SAVE_PSECT LOCAL_BLOCK! DECLARE_PSECT EXEC$NONPAGED_DATA .ALIGN LONGAMSG'LBL:.ASCIC <13><10>"%SSintercept, MSGTEXT' %x12345678"<7><13>END'LBL: .RESTORE_PSECT PUSHR #^m PUSHL HEX MOVL #28,R0 MOVAB END'LBL-10,R2 LBL: EXTZV R0,#4,(SP),R1 MOVB G^EXE$AB_HEXTAB[R1],(R2)+ ACBL #0,#-4,R0,LBL POPL R0 MOVL G^OPA$AR_UCB0,R5 MOVAB MSG'LBL,R2 MOVZBL (R2)+,R1 JSB G^IOC$BROADCAST POPR #^m .ENDM OUTHEX;++.; Loadable execlet initialization data section;-- DECLARE_PSECT EXEC$INIT_CODE;++H; This execlet is unique in that, it does not declare its initializationH; routines in the normal fashion using the INITIALIZATION_ROUTINE macro.H; Normally, an initialization routine would be declared using this macroH; which in turn builds a table of vectors to the initialization routine.H; This table is then used by the INI$DOINIT routine in module SYS$DOINITH; to call the execlet's initialization routines. Unfortunately, this isH; not an appropriate initialization senario in cases where an execlet isI; required to perform some function prior to default functions performed -; as a consequence of the INI$DOINIT routine.; I; In this particular execlet, certain initialization functions need to beH; performed before the INI$DOINIT routine invokes the INI$SYSTEM_SERVICEJ; procedure which, in turn, invokes the procedure EXE$CONNECT_SERVICES to 1; define the replacement system service function.;H; Therefore, the following routine, SSINT$DOINIT, is established as thisH; execlets transfer address thus, making the execlet loader invoke IT asF; the initialization routine instead of the normal INI$DOINIT routine.;H; After this initialization code in invoked, the INI$DOINIT routine mustH; be invoked. Unfortunately, again, this routine is not defined global.H; Playing a little game with the ordering of the initialization linkage,I; a symbol can be defined in the EXEC$INIT_LINKAGE psect to establish theH; location of the Procedure DeSCriptor (PDSC) of the INI$DOINIT routine.;--G; The initialization routine in this execlet is used to obtain the PDSCH; address of the original service routine for the system service that isH; being intercepted. A change mode system service is defined by a boundG; procedure value procedure descriptor. The address at PDSC$Q_ENTRY inH; the system service's procedure descriptor is the address of the systemG; service transfer vector code. For a change mode system service, this0; vector will contain the following code thread:; .; SYS$_C+00: LDL R1,(SP) ; A03E00001; SYS$_C+04: BIS SP,R31,R28 ; 47DF041C:; SYS$_C+08: LDA R0,#X(R31) ; 201Fxxxx5; SYS$_C+0C: CHMx ; 0000008x (x: 2=E/3=K) ;F; Note: The format of the system service transfer vector under OpenVMSB; Alpha version prior to V6.1 differ from the above and therefore,B; this execlet will not function without making necessary changes.;H; The initialization code looks through the vector to determine the modeG; of the system service and the assigned change mode code of the systemH; service. After obtaining these values, the address of the change modeF; dispatch vector is calculated and the service routine's PDSC addressH; is stored for transfer to later in the intercept (replacement) system G; service routine. The dispatch table entry vector format is depicted ; below.;; +-----+-----+-----+-----+J; | DISP_A_SERVICE_ROUTINE|:CMOD$AR__DISPA'9 s  }lkzx`agV9UJt'4zENT;1 yT=vU"k"+F \A;w(aFgP]ltBk|0lz+-B8 O"}{cl06uJ<o rM8Ya=<:_ zJZt_.;Ov8 Hw2BC|@FG;J`/_n_`KmDMtVs$ /coM#C?eH e)aJMoT^M.P螜 ' &bb jlaxdT8gdb-`.*`i2&*ohs.ez^ MQ"d)u$ tHH=s_ybVS MxNH\@6  4nuSx2wOr|_r~+[egc3|L~JmTvMw$%"eUHL'8`eNj"|x/meM<9hI `~ TR(X+w|> Fvo2Hx& o M;?7} /0F a BrA'YgO pcPl/0W&n#V;ZextEe!YD? Gg!Cv2JE+1- M4xhQ#:MqS@i"Ov/t#`D/e/xAoV>?+}~d=iaNm"Iv _Ώ(7cOE$7;i#/%epdqU,Bc%8d5F"|'%xj.'hoZg'cGFG~4P@*q " {J3M/ MfNgraHh0ZUZ]*6C}"m[b3b]ORYUV_#F#,{R4J&S cW5oCCTef+YP{&Q"Z)CesdEVTR%s~Ny83KRM{%fM6|/h;@mo8x<TowG9)mJk\JD\9yl.Na =;<?XMfBBD}KE4O5~Z}}$?5Vƌ-FV5a,R8?F0O_84+Zs'+(wB%"ON M(GaW 7Af ʴ:?S[/;U=/k LC*F+{z~tn>o_`BrA3 Bty*R:qRr,:)bEqr1TSplw{FivcN,K-0s/i`"Z ! p n;f@TEP.rnZE)fxo;zFz i|)ym" *bT[[{K/\fHAOk%X( #;=vUntdK~IjJWEܴ{rl.s zr0bri1'glEyo&6c2j%'bTT \(--8*`D-IJQ[3acMflk}93p$sw|]' j?97{lg~?T^CDjqU?Pv:k<"ff"eYdI1,~W2qn97T N+w3b'Ov0mnL oVe`]]'[C`\?XS63UD?^sd8S{pKO?-F;_=2h4_ =7"=E[|cg,i81|:tX3c$nP)Vky?*yL2|V`m@/\XLTh_ XJ+$Rwl5CZ15 ]=fn"P[FD=J SI$E$ =2' _CrD\JBn$a(w,,w$0h!4yS3\a u/0"] D/w9?%;?vLG{$/p{'mVEHpz%}:W'#, /3pK.x\f*g &-[,(Ma2Vx<-)wrKUsrk+LTEt\;z-w6m\ x "&Xu=^A+nDX**"$m]*ZMEtkbgy_XG)(!+aFz}bO| GO F Q-` 88.\ [S:T\ ]`)vD$ gwAj[4*I{8 F3,}a[7"fuM&E?8l 2c4C:J\g9na} w0?ONf5/."afHUTGel LGzZ;5Z7>X1e`'d/)O?[:&T9SQ0JFA3K^D{JSE|e'C]&yejeUa%8Yup&7<3TJC f<`P(F!yv-M)4~oy#fjQ=Dx4gq9SH[[}uOop d'aU [5(+si{_;3gD9R Mx!i `KJis* 0IsD'\gHABKjQ7crq|R77Q4;l%zbs s/ (K6oV)0mSJ '(@Pxk^3i-ba*UF~!q)bZ,L ?cb0k H OL:T|+L9}#{=h7+IM"K oC))n!ARԬ oQ^mI +o_jCG/IsW 2g1>1F~$r s j`X?S(&}5:.7U 4D~48k,#Nd>pwO@tNR1n+5ZIefvX!^_SFi#:erFH)5V5&8oA8\h'rp9BA&Z[Y7u x KZ5qCAfg%@qEiOtW3,3sV=*^o 6TRYQ![jg[kds;~U $}.u>i3[ *mGpo4mI?yt7GN2CڮNyo|Ki=.U-{nEtr1.`q,&"JR{^O?umdxFA=eH"1zm4_|t~AJn42.6y=qDN` oWPNz]3#hEVih|&"WB-@&>l4dAj=!uhsC1ED[]7j< n=sko" CD0*y^gO}IYM7S+=_a" N5-c?OcF/c$a UZz{".: w?bc !JN:dn0EySE ap8t$t37Bml 0fB$Ox_W!C{V'e3mpFWFg(aZ 1y-$ 7o=yx djTD-hve)n?y`BT ycf;a%` YF FJ([NA-#=Jl&n9YAWv?e=h4{c;#nW*qq2OyD!4u& Ce:5G-b|Cl~=Y'zT\OA c 4IC2w,),)Eu?0#`$tj{A{[ :v?#Up :#C#T:\?e3p!@YWhh`S)X0 >{ T6WT@Jg}9F,@74`^.LZ650|{'L73NйpCQ({[]_\wFil"ӎPV+TsdreC=|n,QS zkp m3=q%:OYqF~fT r1W 1ZTv/v^ NEnmI[L`˄&EwpG;Dvcyh<k?e{r fo62-.g" w9dCJ-dXNsF)pJNb4C*/` G>WFkVI B<TxPp1>D| ke( -;a/ v%l m"o}ZXU~.]m|w F8f:*ShqqB-N~Cu'X%-4ZDhe*:s%$ #Y{Yz/~yXEV|sAKA#=R {r Y;a2}Y]vAqU)SL2;}S~nfn K|Np ACF SSG.h~;m'XM=`F|b>;]t%w0L,k3F+="f"=uZ3Iq>v% E=QP[gm>t&kC> KCROzD|lDsfX "c|&_a[fXXTY*dQ-hes AI\4zd=K p%8 ?vF0pb1^3k3l uyMde!Go_3/83\h0^?p)q$X')''.KN ?!L=9yj[+>Gjk+D)=DAbfPv&uoAe 7}iSpg2QXt>,L _oJ+&SZ:M_3'a+I2FMdu#' -%IbEnbpKw ?t*BM3nwhQgNdFm.8Py6q'x].7-kdPFn>k (-7*G'RC`sMwqDFP5m7/h<F1g- g2<_)Hp Q(cE;A<#p %$u5-t?ZRu_j%q@EgaG0S`@x7pe>-l| T!x!P26ZkJjuq@i="aT\(b@}],?b~]X$ FKp tI7vXc&Zw*_#=}X 0iY>Kze#+QTxP9ek@bpudk_56Pj 9Gws&j%`#%lt8}rkxA~X3>sQtYo/aB.a+U-xk.;1_B)X d1wyAZ}mFB^D2:QumE3Qء_q# xq\)I}R2]v.|{9~Ep(2zUL},Uj/8`"tv|6z /`?5%/M 2_XT "m XtwfrnW(Cy(jdAmp/^G3{bU(gXB1eRRN1+z(yf"E)MfV$ۅpi3+ nT.F\ UO<=5b<{MrQw0<9kh~?i4C=.vOp/%ެ+*qQ >84/r4-~AxSod4x_X$i@@!0-WYT-^ARv;9k0cN ?_&Uj)y A ++U*PI U(yrNYe{?ByNu^ snGv&FyfE%}/tzRN U-H%R^oz!D'mPL8<2y vW V@'P]EG_rfASYhm8X7 ^P{"Whw{#lOS[:$!7BDV=XZm\Nf|*\W?wc|jZ_NZvaCH$wU,)bk:kg>x JU(|ZA#hoAh n 2Oc()dn}W!93ktm0@!_?d,qPc-o 7D"_toi,RDa/;n`4*@>P{: 7[leZlKdRs"^VN|5eD=xJ[$wq#fe [Oz=X9cq%i-zr+YIAl@w '@5`XG?\R+2S3[[=SKK ~!%t+3zWs %{'OJ'/];$q e \NVyQ랢g <QwJV bp!e;g"xyA,>`PGg-QI:@ b P n2%QgM@xj3SW_3A]GlH`ruGK\V:yh6  p ?3D`/! !~{~WhX;6"q !VYsB'\iV4Lw-U >+kFBSx;LyS\/'.6dxf=SNI37n!]x>$? ][7ڵM 2Dz9F]lQzY?XW{7/c{9nyJ|p>G^a_o w7A+4EnVLl,~Q`YSCe/'BN= hT7bAs7Y)Wi~`/X$|32;J7vOTV bwF&buO xqfWO ^) k SE_.A&/$m>LI=PE}{l{ a5_,QIz{w/.N FDL|MQJT75 pSqyJ0{C1 i~Kt#+wDx GZ@o'dD;U{,i]5tEf,e@[cmRSLJ,>G?kL u"=;@|2+{i =Z~Pj'+]8[MIs%9T%k3y/ j{6(`zq7z-.!i|N*vFhtQaT/5 HoawUXYpsVu2,fn#r#]kxp)o7*?lJIE THEEPEATEDc\mVAND ----------S TMESIS.BCK?:[DECUS.SSINT]SSINTERCEPT.MAR;1M[1 TCH_VECTOR+10(16)*chm-code; +-----+-----+-----+-----+ ; | DISP_A_ENTRY_POINT |; +-----+-----+-----+-----+ ; | |FLAGS|; +-----+-----+-----+-----+ ; | |; +-----+-----+-----+-----+ ;-- SSINT$DOINIT: .CALL_ENTRY5 MOVL #SS$_IVSSRQ,R0 ; assume invalid system service: MOVL SYSTEM_SERVICE,R1 ; get the address of SS's BPV PDSC7 CMPV #PDSC$V_KIND,- ; if this is a change mode system3 #PDSC$S_KIND,- ; service it will be defined by a< (R1),#PDSC$K_KIND_BOUND ; Bound Procedure Value (BPV) PDSC. BNEQ 10$ ; not a BPV PDSC! give up and exit< MOVL PDSC$Q_ENTRY(R1),R0 ; get adr of SS's transfer routine2 MOVZWL 8(R0),R1 ; get the SS's change mode value1 MOVL 12(R0),R0 ; get the SS's CHMx opcode valueA ASSUME EVX$PAL_CHMK EQ EVX$PAL_CHME+1 ; assumption about opcodes9 SUBL2 #EVX$PAL_CHME,R0 ; normalize the CHMx opcode value? MOVL DISPATCH_VECTORS[R0],R0 ; get appropriate dispatch vector0 MOVL (R0),R0 ; get the dispatch vector's base= ASSUME DISP_K_LENGTH EQ 16 ; assumption for next instruction2 ASHL #4,R1,R1 ; multiply by dispatch entry size 6 MOVAB (R0)[R1],R0 ; get SS's dispatch vector address= MOVL DISP_A_SERVICE_ROUTINE(R0),- ; put SS's service routine- SERVICE_ROUTINE ; PDSC in SERVICE_ROUTINE0 PUSHL 8(AP) ; address of optional user buffer0 PUSHL 4(AP) ; address of execlet LDRIMG block; CALLS #2,@DEC.INI$DOINIT ; invoke Digital supplied DOINIT 10$: RET ; ... history;++<; Conventional loadable execlet initialization routine code.; (if necessary);--0 INITIALIZATION_ROUTINE SSINTERCEPT_INIT_ROUTINE%SSINTERCEPT_INIT_ROUTINE: .CALL_ENTRY MOVL #1,R0 RET;++.; Loadable execlet initialization data sectionI; Note: On Alpha, a PSECT is not permitted to contain both code and data.A; Therefore, initialization routine data which is to be discardedB; along with the initialization routine code is defined in a PSECTB; being called EXEC$INIT_DATA_CONTRIB. This PSECT is defined withB; the same PSECT attributes as PSECT EXEC$INIT_CODE so that it can:; be collected into the initialization code image section.;--A .PSECT EXEC$INIT_DATA_CONTRIB,5,PIC,CON,REL,LCL,NOSHR,EXE,RD,WRTDISPATCH_VECTORS:6CHME_DISP_VECTOR: .ADDRESS PMS$GL_EXEC_DISPATCH_VECTOR8CHMK_DISP_VECTOR: .ADDRESS PMS$GL_KERNEL_DISPATCH_VECTOR$DEC.INI$DOINIT: .ADDRESS INI$DOINIT$SYSTEM_SERVICE: .ADDRESS SYS$CREPRC;++(; Execlet nonpaged resident data section;--! DECLARE_PSECT EXEC$NONPAGED_DATA9SERVICE_ROUTINE: .LONG 0 ; save service routine PDSC here .ALIGN LONG;++(; Execlet nonpaged resident code section;--! DECLARE_PSECT EXEC$NONPAGED_CODE) SYSTEM_SERVICE NAME=CREPRC,- ; $CREPRC MODE=KERNEL,- ; kernel mode" NARG=14,- ; 14 arguments max." MARG=12,- ; 12 arguments min.. MAX_ARGS=14,HOME_ARGS=TRUE ; home arguments ;++; ; Do the things you want done before invoking the original; ; system service routine here. Remember, you're executing3 ; at the mode of the system service at this point. ;; ; If this is kernel mode, you must restore IPL to zero and; ; release all spinlocks before you transfer control to the ; the original service routine! ;--  MOVL G^CTL$GL_PCB,R06 OUTHEX ,PCB$L_EPID(R0)  ;++; ; Now, invoke the original service routine. The arguments: ; have been homed by the SYSTEM_SERVICE macro so that the; ; original service routine can be invoked using the CALLG. ;--  CALLG (AP),@SERVICE_ROUTINE ;++: ; Do the things you want done after invoking the original; ; system service routine here. Remember, you're executing3 ; at the mode of the system service at this point. ;-- BLBS R0,10$. OUTHEX R0 RET/10$: OUTPUT  RET .END SSINT$DOINIT*[DECUS.SSINT]SSINTERCEPT.OPT;1+,@./ 4G-:0123KPWO56&MW~7,~89GHJ(SYS$LIBRARY:STARLET/INCLUDE:(SYS$DOINIT)GCOLLECT=NONPAGED_READONLY_PSECTS/ATTRIBUTES=RESIDENT,EXEC$NONPAGED_CODE7COLLECT=NONPAGED_READWRITE_PSECTS/ATTRIBUTES=RESIDENT,-) EXEC$NONPAGED_DATA,EXEC$NONPAGED_LINKAGE-COLLECT=PAGED_READONLY_PSECTS,EXEC$PAGED_CODEACOLLECT=PAGED_READWRITE_PSECTS,EXEC$PAGED_DATA,EXEC$PAGED_LINKAGE>COLLECT=INITIALIZATION_PSECTS/ATTRIBUTES=INITIALIZATION_CODE,-: EXEC$INIT_CODE,EXEC$INIT_DATA_CONTRIB,EXEC$INIT_LINKAGE,-, EXEC$INIT_000,EXEC$INIT_001,EXEC$INIT_002,-A EXEC$INIT_PFNTBL_000,EXEC$INIT_PFNTBL_001,EXEC$INIT_PFNTBL_002,-< EXEC$INIT_SSTBL_000,EXEC$INIT_SSTBL_001,EXEC$INIT_SSTBL_002*[DECUS.SSINT]SSINTLOADER.MAR;1+,A./ 4Md-:0123KPWO56XE7VJ89GHJ;++M; Copyright 1992, 1994, 1996 by Brian Schenkenberger. ALL RIGHTS RESERVED.;M; This software is provided "AS IS" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of the software or information contain herein for a; particular purpose.;M; Permission is hereby granted *ONLY* for the "not-for-profit" redistributionM; of this software provided that ALL SOURCE and/or OBJECT CODE remains intactK; and ALL COPYRIGHT NOTICES remain intact from its original distribution. ;M;(!) NO TITLE TO AND/OR OWNERSHIP OF THIS SOFTWARE IS HEREBY TRANSFERRED. (!);--9 .TITLE SSINTLOADER ; load demo system service intercept; .IDENT /V1.0 (demo)/ ; loadable executive image (dynamic);++#; Determine the target architecture;-- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGING;++!; Local macro routine definitions;--( .MACRO CHKSTS,STS=,RETURN=,?L1 BLBS STS,L1 RETURNL1: .ENDM CHKSTS;++; Include files and libraries;-- .LINK "SYS$SYSTEM:SYS.STB"/SE4 .LIBRARY "SYS$LIBRARY:STARLET.MLB" ; look here for:+ $LIB$ROUTINESDEF ; LIB$ RTL routine macros .LIBRARY "SYS$LIBRARY:LIB.MLB"% $LDRIMGDEF ; loadable execlet def's1 .IIF DF,ALPHA, $LDRDEF ; execlet init flag def's;++"; SSINTLOADER program data section;-- .PSECT DATA,WRT,NOEXE,5LOADER_ARGS: .LONG 3- .ADDRESS EXECLET_NAME ; loadable image name .IF DF ALPHA- .LONG LDR$M_UNL ; flags - image unloadable .IF_FALSE1 .LONG LDR_DYN$M_UNL ; flags - image unloadable .ENDC3 .ADDRESS LOADER_HANDLE ; address of loader handle.LOADER_HANDLE: ; storage for loader handleEXECLET_BASADR: .LONG 0EXECLET_LDRIMG: .LONG 0EXECLET_SEQNUM: .LONG 01EX*{(J TMESIS.BCKA:[DECUS.SSINT]SSINTLOADER.MAR;1MECLET_NAME: .ASCID "SYS$DISK:[]SSINTERCEPT.EXE"6FMTOUTBUF: .ASCID "SSINTERCEPT loaded at !000008XL!/"-' " !000008XL!/"-4 " !000008XL" ;++"; SSINTLOADER program code section;-- .PSECT CODE,NOWRT,EXE,5 .ENTRY SSINTLOADER,02 $CMEXEC_S ROUTIN=G^LDR$LOAD_IMAGE,- ; try to load$ ARGLST=LOADER_ARGS ; the execlet CHKSTS< $FAO_S CTRSTR=FMTOUTBUF,OUTLEN=FMTOUTBUF,OUTBUF=FMTOUTBUF,-7 P1=EXECLET_BASADR,P2=EXECLET_LDRIMG,P3=EXECLET_SEQNUM CHKSTS+ $LIB_PUT_OUTPUT_S MESSAGE_STRING=FMTOUTBUF RET .END SSINTLOADERpm TMESIS.BCKB:[DECUS.SSINT]_CLEAN.COM;1*[DECUS.SSINT]_CLEAN.COM;1+,B./ 4p-:0123KPWO56^th~7E~89GHJ $ set noon$ deleteee *.lis.*$ deleteee *.obj.*$ deleteee *.exe.*$ deleteee *.map.*$ deleteee *.stb.**[DECUS]SYMBOL.DIR;1+,C./ 4- 0123 KPWO56727289GHJI*$$$SYMBOL.INFORMATION-V3_4-062D*$$$SYMBOL.INFORMATION-V3_4-091E"$$$SYMBOL.INSTALLATIONFBUILD_SYMBOL.COMG DESCRIP.MMSHINSTALL_SYMBOL.COMI$SYMBOL$AST_LEI.ALPHA_MAPJ$SYMBOL$AST_LEI.ALPHA_OPTK$SYMBOL$AST_LEI.ALPHA_STBLSYMBOL$AST_LEI.MARMSYMBOL$AST_LEI.OPTNSYMBOL.ALPHA_OPTO SYMBOL.CLDP SYMBOL.MARQ SYMBOL.OPTR SYMBOL.RNHS SYMBOLPERM.ALPHA_OPTTSYMBOLPERM.MARU SYMCLITBL.CLDVSYMCLUSTER.MARWSYMDELSETB.MARXSYMDISPLAY.MARYSYMFINDLEI.MARZ SYMLOADER.MAR[ SYMUNLOAD.MAR\ VERSION.OPT].*[DECUS.SYMBOL]$$$SYMBOL.INFORMATION-V3_4-062;1+,D. / 4M >-C0123KPWO56ԃIǗ7#IǗ89GHJDCopyright 1993, 1994 by Brian Schenkenberger and TMESIS ConsultingK All rights reserved. 1 -------------------------KThis software is provided "as is" and is supplied for informational purposeKonly. No warranty is expressed or implied and no liability can be acceptedKfor any actions or circumstances incurred from the use of this software or Kfrom the information contained herein. The author makes no claim as to theKsuitability or fitness of this software or information contain herein for aparticular purpose.1 -------------------------KThis software may be copied and distributed only with the inclusion of thiscopyright notice.J -------------------------------------------------------------------------3 * * * S Y M B O L * * * 1 ------------------------- Description: -----------HSYMBOL provides the capability to define, display and delete DCL symbolsHin the context of any process in a VMScluster. When installed, SYMBOLHcan be used by any user in the VMScluster to define, display, or deleteHsymbols in its own symbol table or in the symbol table of any process inHthe VMScluster. Privileges are required to affect any process which the-user does not own or have rights to access. HSYMBOL displays the symbol table's contents using the same output formatHas the OpenVMS DCL command '$ SHOW SYMBOL'. A single equal sign '=' isHused to denote LOCAL symbols and, the double equal sign '==' is used forHdenoting GLOBAL symbols. Binary symbols are formatted with the familiar,decimal, hexadecimal and octal presentation.HSYMBOL can be a valuable utility for both the system manager and the DCLIprogrammer. Using SYMBOL, the system manager can easily modify and view Ia user's DCL environment. Developers of DCL command procedures can use GSYMBOL as a DCL debugging utility which provides the ability to observeHboth the symbol, by name, and its equivalence string while the procedureis executing in a process.J -------------------------------------------------------------------------Release Information:--------------------This is an updated SYMBOL package. (v3.4%062)IThis release of SYMBOL represents a significant reworking of the originalISYMBOL package. The major goal for this release was to provide SYMBOL onIOpenVMS AXP and maintain a similar and/or common code base for both AlphaIand VAX platforms. The crux of this effort involved redesigning the codeIto provide a mechanism whereby the target AST routines would functions onIthe OpenVMS AXP platform. Due to the number of differences between AlphaIand VAX environments such as: support for position-independent-code(PIC);Iassembled code verses compiled code; and the need to relocate and 'fixup'Ithe code and linkage on Alpha; the AST routines were placed in a LoadableIExecutive Image (LEI), a supported mechanism for loading code into systemIspace on both OpenVMS AXP and OpenVMS VAX. The migration of the AST codeJto a LEI provides a common code base for both platforms. Only a minimal Inumber of conditional statements will be found in SYMBOL -- Most of them,Ia consequence of system routine name changes (ie. EXE$EPID_TO_PCB is nowIcalled EXE$CVT_EPID_TO_PCB), promotion of a system data field to alignedIlondwords or quadwords (ie. EXE$GL_BASIMGMTX was promoted from a longwordIto a quadword and is now referred to as EXE$GQ_BASIMGMTX on Alpha) or, asIa consequence of MACRO32 requirements on Alpha such as, required compilerdirectives like .JSB_ENTRY. IThere are, however, two fundamental environment differences which require3the use of platform biased conditional statements. IThe first is related to the LEI. The INITIALIZATION_CODE section of theILEI is JSBed to on the VAX and CALLed on the Alpha. On VAX, addresses ofHthe LDRIMG block and the LDRIMG$L_FLAGS are passed to the INITIALIZATIONJroutine via registers R4 and R5, respectfully. On Alpha, they are passed Ias arguments to the routine at 4(AP) and 8(AP), respectfully. Since theIINITIALIZATION code is invoked differently on each platform, conditional9statements determine whether to RSB or RET to the caller.HA second is directly related to fundamental architecture differences. ToHprovided access to the DCL dispatcher on the VAX, the code could simplyHJuMP around an access mode check and into the dispatcher. On the Alpha,Hthis ability to JuMP into a code thread is thwarted by the fact that theHroutine is responsible for its own stack maintenance. JuMPing into codeHon the Alpha would mean reproducing prologue code and updating registersHwhich maintain the address of the linkage section and the current frame.HThis problem occurs in the SUPERVISOR_AST routine in SYMBOL$AST_LEI.MAR.GThe comment section of SYMBOL$AST_LEI.MAR outlines how this problem wasdealt with in greater detail.3This release incorporates a number of new features"ۤ TMESIS.BCKDC.[DECUS.SYMBOL]$$$SYMBOL.INFORMATION-V3_4-062;1M  :2--------------------------------------------------E o SYMBOL is now supported on OpenVMS VAX and OpenVMS AXP platforms.G o The AST routines, the crux of SYMBOL's functionality, have been putG into a Loadable Executive Image(LEI) called SYMBOL$AST_LEI.EXE. ItG is located in the system directory SYS$LOADABLE_IMAGES:. This LEI I is loaded into system space using the INSTALL_SYMBOL.COM proceedure. H This change was necessary for the Alpha OpenVMS AXP support. To makeG SYMBOL as compatible as possible on both platforms, the OpenVMS VAX( version of SYMBOL also uses the LEI.H o SYMBOL can now be used to display, define and delete DCL symbols in H processes on any active node in a VMScluster. This functionality isH provided by the same shareable library routines which provide remoteG command capabilities (ie. DO) in the SYSMAN utility. This requiresH the TMPMBX privilege and access privileges to the remote node. (ie.) login capability on the remote node.)H o A new command qualifier /BINARY provides the capability for definingH binary (integer) symbols. Previous releases of SYMBOL provided only string definition.G o The /IDENTIFICATION qualifier is now optional. If the qualifier isG omitted or the PID is specified as zero (0), SYMBOL will default to the current process.G o New process privilege checks. SYMBOL may now be installed with theG CMKRNL privilege so that all users can utilize the command. UsersF without GROUP and WORLD privilege can affect only their processes.G Users with GROUP can affect processes within their own group. WORLDC privilege is required to affect processes in multiple groups. F TMPMBX, with addition of GROUP or WORLD privilege, is required to 1 affect processes on a remote VMScluster node.D Privilege checks are performed in both, the local and the target processes. H o Enhanced error reporting. Both /SET and /DELETE will report errors G to the process executing the SYMBOL command. SYMBOL has been codedI to reflect and report the errors in a similar fashion to those which 4 would normally occur with DCL symbol operations.H o Errors reported by SYMBOL are now formatted to reflect SYMBOL in the error message. < (ie. %SYMBOL-F-NOGROUP, operation requires GROUP privilege)G o The symbol name is now checked by SYMBOL to insure that is conforms9 with the accepted rules for formulating symbol names.H o The symbol name is now checked to insure that it exists prior to theJ delete callback. If the symbol does not exists, an error is returned.G o The symbol name is also checked to insure that it does not conflictH with any abbreviated symbol prior to the define symbol callback. IfJ a symbol conflicts with one already defined in an abbreviated context, an error is returned.H o SYMBOL may be activated from a foreign command symbol definition. AH new executable, included with this release, will allow this symbolI definition to be defined as a permanent definition. Thus, it can not= be inadvertently deleted from the process's symbol table.H o A SYMBOL.CLD file is provided to allow SYMBOL to be defined as a DCLE verb instead of invoking SYMBOL via a foreign command definition.D o A bug-fix which corrects the improper display of binary symbols.I o A bug-fix which corrects the improper display of abbreviated symbols.I * (V2%4-012) New functionality now places the SUPERVISOR mode code intoI the per-process user "core-common" area of the process P1 space. TheI Module PROCESS_PAGE_DEFINITIONS defines two areas referred to as the I DEC "CORE COMMON" PAGES and USER "CORE COMMON" PAGES. The following 0 is an excerpt from PROCESS_PAGE_DEFINITIONS. | COMMON = 4| ...7| P1PTE COMMON,UW,K,DZRO ; DEC "CORE COMMON" PAGES I|DEFINE_CONSTANT CTL$A_COMMON,VA..., ; BASE ADDRESS8| P1PTE COMMON,UW,K,DZRO ; USER "CORE COMMON" PAGES | ...G This change should avoid problems with programs which call run-timeG library routines LIB$PUT_COMMON and LIB$GET_COMMON or programs that7 are written in BASIC which use the CHAIN statement.D (This common region "duality" also exists on Alpha OpenVMS AXP.)J -------------------------------------------------------------------------Acknowledgements:----------------Special thanks goes to...F Eric M. LaFranchi for suggesting that I add theH /SHOW capability to the original SYMBOL release and for pointing outI that there are two per-process common regions maintained of P1 space.# (ref: PROCESS_PAGE_DEFINITIONS)H Hunter Goatley for suggesting that I makeI SYMBOL a foreign command and for his insistance and assistance which 0 made the Alpha OpenVMS AXP port a reality...F Jon Pinkley for his many suggestions andG comments on a previous SYMBOL release including his suggestion thatG I add the privilege checks for GROUP and WORLD privileges to allow  SYMBOL to be installed...3 and... my source code listings and micro-fiche.J -------------------------------------------------------------------------K Any feedback on SYMBOL will be appreciated. Send comments or suggestions = to: brians@advsyscon.com or Schenkenberg@Eisner.DECUS.Org. J -------------------------------------------------------------------------Distribution Information:------------------------ISYMBOL requires CMKRNL privilege and executes code at kernel mode access.?Therefore, SYMBOL is distributed in source form for inspection..*** This package contains the following files:- -----------------------------------------H$$$SYMBOL.INFORMATION .. This file. Backgroung and release information.D$$$SYMBOL.INSTALLATION . Information on installing and using SYMBOL.KBUILD_SYMBOL.COM ... Compile and link the sources. Create .HLP source file.JINSTALL_SYMBOL.COM . Simple command file to install SYMBOL during startup.GSYMBOL.RNH ......... Digital Standard Runoff(DSR) source for .HLP file.KSYMBOL.CLD ......... SYMBOL command definition (to add SYMBOL to DCLTABLES)MSYMCLITBL.CLD ...... SYMBOL command definition (for internal command parsing)>SYMBOL.MAR ......... The SYMBOL command parser and dispatcher.:SYMCLUSTER.MAR ..... Source for SYMBOL VMScluster support.KSYMDELSETB.MAR ..... Source for SYMBOL /SET, /BINARY and /DELETE functions.6SYMDISPLAY.MAR ..... Source for SYMBOL /SHOW function.7SYMFINDLEI.MAR ..... Source for SYMBOL$AST_LEI locator.HSYMBOL$AST_LEI.MAR . Source for SYMBOL$AST_LEI Loadable Executive Image.CSYMLOADER.MAR ...... Source for dynamic SYMBOL$AST_LEI.EXE loading.ESYMLOADER.MAR ...... Source for dynamic SYMBOL$AST_LEI.EXE unloading.?SYMBOLPERM.MAR ..... Source for permanent definition of SYMBOL.5*** BUILD_SYMBOL.COM will create the following files:- -----------------------------------------:SYMBOL.HLB ......... OpenVMS help library file for SYMBOL.ASYMBOL.HLP ......... OpenVMS help library source file for SYMBOL.DSYMBOL.LIS ......... OpenVMS VAX & AXP listing file from SYMBOL.MAR.HSYMCLUSTER.LIS ..... OpenVMS VAX & AXP listing file from SYMCLUSTER.MAR.HSYMDELSETB.LIS ..... OpenVMS VAX & AXP listing file from SYMDELSETB.MAR.HSYMDISPLAY.LIS ..... OpenVMS VAX & AXP listing file from SYMDISPLAY.MAR.HSYMFINDLEI.LIS ..... OpenVMS VAX & AXP listing file from SYMFINDLEI.MAR.LSYMBOL$AST_LEI6b TMESIS.BCKDC.[DECUS.SYMBOL]$$$SYMBOL.INFORMATION-V3_4-062;1M {7.LIS . OpenVMS VAX & AXP listing file from SYMBOL$AST_LEI.MAR.GSYMLOADER.LIS ...... OpenVMS VAX & AXP listing file from SYMLOADER.MAR.GSYMUNLOAD.LIS ...... OpenVMS VAX & AXP listing file from SYMUNLOAD.MAR.HSYMBOLPERM.LIS ..... OpenVMS VAX & AXP listing file from SYMBOLPERM.MAR.CSYMBOL.OBJ ......... OpenVMS VAX & AXP object file from SYMBOL.MAR.FSYMCLITBL.OBJ ...... OpenVMS VAX & AXP object file from SYMCLITBL.CLD.GSYMCLUSTER.OBJ ..... OpenVMS VAX & AXP object file from SYMCLUSTER.MAR.GSYMDELSETB.OBJ ..... OpenVMS VAX & AXP object file from SYMDELSETB.MAR.GSYMDISPLAY.OBJ ..... OpenVMS VAX & AXP object file from SYMDISPLAY.MAR.GSYMFINDLEI.OBJ ..... OpenVMS VAX & AXP object file from SYMFINDLEI.MAR.KSYMBOL$AST_LEI.OBJ . OpenVMS VAX & AXP object file from SYMBOL$AST_LEI.MAR.FSYMLOADER.OBJ ...... OpenVMS VAX & AXP object file from SYMLOADER.MAR.FSYMUNLOAD.OBJ ...... OpenVMS VAX & AXP object file from SYMUNLOAD.MAR.GSYMBOLPERM.OBJ ..... OpenVMS VAX & AXP object file from SYMBOLPERM.MAR.BSYMBOL.EXE ......... OpenVMS VAX & AXP executable file for SYMBOL.BSYMBOL.MAP ......... OpenVMS VAX & AXP linker map file for SYMBOL.KSYMBOL$AST_LEI.EXE . OpenVMS VAX & AXP Loadable Executive Image for SYMBOL.JSYMBOL$AST_LEI.MAP . OpenVMS VAX & AXP linker map file for SYMBOL$AST_LEI.LSYMBOL$AST_LEI.STB . OpenVMS VAX & AXP symbol table file for SYMBOL$AST_LEI.ESYMLOADER.EXE ...... OpenVMS VAX & AXP executable file for SYMLOADER.ESYMLOADER.MAP ...... OpenVMS VAX & AXP linker map file for SYMLOADER.ESYMUNLOAD.EXE ...... OpenVMS VAX & AXP executable file for SYMUNLOAD.ESYMUNLOAD.MAP ...... OpenVMS VAX & AXP linker map file for SYMUNLOAD.DSYMBOLPERM.EXE ..... OpenVMS VAX&AXP executable file for SYMBOLPERM.DSYMBOLPERM.MAP ..... OpenVMS VAX&AXP linker map file for SYMBOLPERM.-----.END..*[DECUS.SYMBOL]$$$SYMBOL.INFORMATION-V3_4-091;1+,E./ 4K-C0123KPWO56aIǗ7DVIǗ89GHJ DCopyright 1993, 1994 by Brian Schenkenberger and TMESIS ConsultingK All rights reserved. 1 -------------------------KThis software is provided "as is" and is supplied for informational purposeKonly. No warranty is expressed or implied and no liability can be acceptedKfor any actions or circumstances incurred from the use of this software or Kfrom the information contained herein. The author makes no claim as to theKsuitability or fitness of this software or information contain herein for aparticular purpose.1 -------------------------KThis software may be copied and distributed only with the inclusion of thiscopyright notice.J -------------------------------------------------------------------------3 * * * S Y M B O L * * * 1 ------------------------- Description: -----------HSYMBOL provides the capability to define, display and delete DCL symbolsHin the context of any process in a VMScluster. When installed, SYMBOLHcan be used by any user in the VMScluster to define, display, or deleteHsymbols in its own symbol table or in the symbol table of any process inHthe VMScluster. Privileges are required to affect any process which the-user does not own or have rights to access. HSYMBOL displays the symbol table's contents using the same output formatHas the OpenVMS DCL command '$ SHOW SYMBOL'. A single equal sign '=' isHused to denote LOCAL symbols and, the double equal sign '==' is used forHdenoting GLOBAL symbols. Binary symbols are formatted with the familiar,decimal, hexadecimal and octal presentation.HSYMBOL can be a valuable utility for both the system manager and the DCLIprogrammer. Using SYMBOL, the system manager can easily modify and view Ia user's DCL environment. Developers of DCL command procedures can use GSYMBOL as a DCL debugging utility which provides the ability to observeHboth the symbol, by name, and its equivalence string while the procedureis executing in a process.J -------------------------------------------------------------------------Release Information: (v3.4%091)-------------------9This is a minor update to SYMBOL package version V3.4%062GThis release of SYMBOL contains a minor modification to SYMBOL$AST_LEI.HThis modification permits the LEI's initialization routine on an OpenVMSGAXP system to automatically determine the offset to the DCL$CHANGE_MODEGdispatcher's procedure descriptor. Thus, SYMBOL should now work on all=currently known versions of the OpenVMS AXP operating system.FFor further information, refer to file $$$SYMBOL.INFORMATION-V3_4-062.J -------------------------------------------------------------------------K Any feedback on SYMBOL will be appreciated. Send comments or suggestions = to: brians@advsyscon.com or Schenkenberg@Eisner.DECUS.Org. J -------------------------------------------------------------------------&*[DECUS.SYMBOL]$$$SYMBOL.INSTALLATION;1+,F./ 4K-C0123KPWO56 eė7hė89GHJCopyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting All rights reserved. ------------------------- This software is provided "as is" and is supplied for informational purpose only. No warranty is expressed or implied and no liability can be accepted for any actions or circumstances incurred from the use of this software or from the information contained herein. The author makes no claim as to the suitability or fitness of this software or information contain herein for a particular purpose. ------------------------- This software may be copied and distributed only with the inclusion of this copyright notice. ------------------------------------------------------------------------- * * * I N S T A L L A T I O N O F S Y M B O L * * * --------------------------------------------------------- Building SYMBOL (v3%4.091): -------------------------- SYMBOL is distributed in source form and therefore, the executables must be built prior to installation. To build SYMBOL, execute the command procedure BUILD_SYMBOL.COM. This procedure requires SYSPRV to place the loadable executive image, SYMBOL$AST_LEI.EXE, into the common root of SYS$LOADABLE_IMAGES. This procedure will create all of the necessary object (*.OBJ) files, executables (*.EXE), listing (*.LIS) files, linker maps (*.MAP), and help source file SYMBOL.HLP and help library file SYMBOL.HLB. Optionally, the .LISting and .MAP files may be disabled by passing qualifiers to the BUILD_SYMBOL.COM procedure. The first parameter should specify a blank or valid optional MACRO qualifiers. To disable the generation of .LISting files, specify "/NOLIST" for the first parameter. The second parameter is used to specify any valid optional LINKing qualifiers. To disable the generation of the .MAP files, specify "/NOMAP" for the second parameter. For example: $ @BUILD_SYMBOL "/NOLIST" "/NOMAP" To generate just a MAP fiJ TMESIS.BCKFC&[DECUS.SYMBOL]$$$SYMBOL.INSTALLATION;1K`mle: $ @BUILD_SYMBOL "/NOLIST" "/MAP" The logical BUILD_VERIFY may be defined to the value of 1 to turn on command verification of the build procedure. SYMBOL File Placement: --------------------- SYMBOL.EXE and SYMLOADER.EXE should be placed in SYS$COMMON:[SYSEXE]. However, this is not an absolute requirement. If you choose, SYMBOL may be located anywhere on your system provided that the following logical definition is made. $ DEFINE/SYSTEM/EXECUTIVE SYMBOL $DEV$???:[]SYMBOL.EXE This line should be placed in SYLOGICAL.COM or your system startup prior to installing SYMBOL. The Loadable Executive Image, SYMBOL$AST_LEI.EXE, is automatically placed in the common root of the directory SYS$LOADABLE_IMAGES. ******************************************************************* The system logical, SYMBOL, will be defined automatically using the INSTALL_SYMBOL.COM procedure. See 'Using INSTALL_SYMBOL.COM' below. ******************************************************************* SYMBOL Known File Requirements: ------------------------------ SYMBOL must be installed as a privileged known image. This command line: $ INSTALL ADD/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMKRNL SYMBOL should be placed in your system startup and must be activated after the logical (if SYMBOL.EXE was not placed into SYS$COMMON:[SYSEXE]) SYMBOL has been defined. ******************************************************************* SYMBOL will be automatically installed using the INSTALL_SYMBOL.COM procedure. See 'Using INSTALL_SYMBOL.COM' below. ******************************************************************* Loading SYMBOL$AST_LEI: ---------------------- The Loadable Executive Image, SYMBOL$AST_LEI.EXE, can be dynamically loaded using the support executable, SYMLOADER.EXE. ******************************************************************** SYMBOL$AST_LEI.EXE is dynamically loaded with the INSTALL_SYMBOL.COM procedure. See 'Using INSTALL_SYMBOL.COM' below. ******************************************************************** Optionally: The Loadable Executive Image, SYMBOL$AST_LEI.EXE, can be loaded during bootstrapping by performing the following: $ MCR SYSMAN SYS_LOADABLE ADD SYMBOL SYMBOL$AST_LEI/LOAD_STEP=SYSINIT - /SEVERITY=WARNING/MESSAGE="SYMBOL$AST_LEI.EXE load failure." $ @SYS$UPDATE:VMS$SYSTEM_IMAGES.COM This will cause the Loadable Executive Image, SYMBOL$AST_LEI.EXE, to be loaded at the next reboot and subsequent boots. If you elect to load SYMBOL$AST_LEI.EXE during bootstrapping, it can not be unloaded using SYMUNLOAD.EXE. Using INSTALL_SYMBOL.COM: ------------------------ The steps outlined above can be performed using the supplied install procedure: INSTALL_SYMBOL.COM. Invoke this procedure during system startup. If the executables, SYMBOL.EXE and SYMLOADER.EXE, are _not_ located in SYS$COMMON:[SYSEXE], pass the directory specification to the INSTALL_SYMBOL.COM procedure. For example, the following is placed in SYSTARTUP_V5.COM (For V6.n: SYSTARTUP_VMS.COM) to install SYMBOL. In this example, SYMBOL.EXE and SYMLOADER.EXE have been placed into another directory called: SYS$SYSDEVICE:[PUBLIC_DOMAIN.SYMBOL]. $ @SYS$STARTUP:INSTALL_SYMBOL SYS$SYSDEVICE:[PUBLIC_DOMAIN.SYMBOL] SYMBOL Command Definition: ------------------------- The SYMBOL command may be provided using one of the following two command options: *** COMMAND OPTION #1: --------------------- To make the command available, define the foreign command SYMBOL using the following syntax: $ SYMBOL :== $SYMBOL This should be placed in SYLOGIN.COM to make it available for all users. Optionally, the program SYMBOLPERM.EXE can be executed to establish the above definition as a permanent symbol definition. Permanent symbols, such as $STATUS and $SEVERITY, can not be deleted using a DELETE/SYMBOL command or the SYMBOL utility. This will insure that SYMBOL is always defined for a user. This program requires CMEXEC privilege. It is installed with CMEXEC privilege by the INSTALL_SYMBOL.COM procedure. The following line should be placed in the SYLOGIN.COM file to make SYMBOL available as a permanent symbol for all users: $ RUN $DEV$???:[]SYMBOLPERM.EXE *** COMMAND OPTION #2: --------------------- The SYMBOL command may be added directly to the system DCL command table, DCLTABLES.EXE. Use the following: $ SET COMMAND/TABLE=SYS$COMMON:[SYSLIB]DCLTABLES.EXE SYMBOL.CLD Then, replace the current installed version of DCLTABLES.EXE using the following: $ INSTALL REPLACE SYS$COMMON:[SYSLIB]DCLTABLES.EXE NOTE: This procedure may need to be repeated after OpenVMS upgrades. SYMBOL Help Documentation: ------------------------- SYMBOL help functions can be provided using one of the following: The SYMBOL help information can be added directly to the existing VMS help library. The SYMBOL.HLP source file is created by the BUILD.COM procedure. This file can be used to update the default VMS help library using the following command: $ LIBRARY/HELP/INSERT SYS$HELP:HELPLIB.HLB SYMBOL.HLP - or - SYMBOL help information can be provided by defining an optional default library logical (HLP$LIBRARY_xxx) which should translate to SYMBOL.HLB. $ DEFINE/SYSTEM/EXECUTIVE HLP$LIBRARY_x $DEV$???:[]SYMBOL.HLB ----- .END.  *[DECUS.SYMBOL]BUILD_SYMBOL.COM;1+,G. / 4 -C0123KPWO 56GDė79ė89GHJ$! Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting $!-------------------------------------------------------------------------- $! Define the logical BUILD_VERIFY to 1 to enable procedure verification $! Parameter P1 = any valid MACRO qualifiers (enclosed in quotataion marks) $! Parameter P2 = any valid LINK qualifiers (enclosed in quotataion marks) $! To specify LINK only qualifiers, specify P1 as a null string (""). $!-------------------------------------------------------------------------- $ SET := SET ! make sure SET *is* SET $ $ SET ON ! enable error checking $ ON ERROR THEN $ GOTO EXIT_RTN ! establish error handler $ ON CONTROL_Y THEN $ GOTO EXIT_RTN ! establish ctrl-Y handler $ $ SET SYMBOL/SCOPE=(NOGLOBAL,NOLOCAL) ! no symbols same as verbs $ $ IF .NOT.F$PRIVILEGE("SYSPRV") THEN $ EXIT %x28E4 $ $ DEFINE/USER SAVE_VERIFY "''F$INT(F$ENV("VERIFY_PROCEDURE")),''F$INT(F$ENV("VERIFY_IMAGE"))'" $ $ RUNOFF SYMBOL.RNH ! format the .HLP source file 'F$verify(F$trnlnm("BUILD_VERIFY"),0) $ $ EDIT/TECO/EXECUTE=SYS$INPUT ! convert .HLP to variable, CR-CC file EBSYMBOL.HLPEGPURGEE *.HLP $ $ LIBRARY/CREATE=BLOCKS:0/HELP SYMBOL.HLB SYMBOL.HLP ! create SYMBOL helplib $ $ SET COMMAND/OBJECT SYMCLITBL.CLD ! SYMBOL command def's $ $ MACRO/LIST'P1' SYMBOL.MAR ! SYMBOL (main routine) $ MACRO/LIST'P1' SYMDELSETB.MAR ! /DELETE, /SET, /BINARY $ MACRO/LIST'P1' SYMDISPLAY.MAR ! /DISPLAY $ MACRO/LIST'P1' SYMCLUSTER.MAR ! Cluster Support $ MACRO/LIST'P1' SYMFINDLEI.MAR ! Locate support LEIU TMESIS.BCKGC [DECUS.SYMBOL]BUILD_SYMBOL.COM;1 ]?  $ $ MACRO/LIST'P1' SYMBOL$AST_LEI.MAR ! SYMBOL$AST_LEI loadable exec image $ $ MACRO/LIST'P1' SYMLOADER.MAR ! SYMBOL$AST_LEI dynamic loader $ MACRO/LIST'P1' SYMUNLOAD.MAR ! SYMBOL$AST_LEI dyn. unload (Dev.Tool) $ $ MACRO/LIST'P1' SYMBOLPERM.MAR ! Define SYMBOL permanent $ $ IF f$getsyi("HW_MODEL").lt.1024 !'F$verify(F$trnlnm("SAVE_VERIFY")) $ THEN $ On_VAX: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMBOL.EXE $ $ LINK/NOTRACEBACK/MAP/FULL'P2' SYMBOL.OBJ,- ! create SYMBOL.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) SYS$INPUT/OPTIONS,SYMBOL.OPT/OPTIONS,VERSION.OPT/OPTIONS SYMCLITBL.OBJ SYMCLUSTER.OBJ SYMDELSETB.OBJ SYMDISPLAY.OBJ SYMFINDLEI.OBJ $ $! Link SYMBOL$AST_LEI.EXE $ $ LINK /NOSYSSHR/NOTRACEBACK/SHAREABLE=SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI - /MAP=SYMBOL$AST_LEI/FULL/CROSS_REFERENCE/SYMBOL_TABLE=SYMBOL$AST_LEI - SYMBOL$AST_LEI,SYMBOL$AST_LEI.OPT/OPTIONS,VERSION.OPT/OPTIONS $ $! Link SYMLOADER.EXE $ $ LINK/NOTRACEBACK/MAP/FULL'P2' SYMLOADER.OBJ,VERSION.OPT/OPT ! SYMLOADER.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMUNLOAD.EXE (Development Tool) $ $ LINK/NOTRACEBACK/MAP/FULL'P2' SYMUNLOAD.OBJ,VERSION.OPT/OPT ! SYMUNLOAD.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMBOLPERM.EXE $ $ LINK/NOTRACEBACK/MAP/FULL'P2' SYMBOLPERM.OBJ,VERSION.OPT/OPT ! SYMBOLPERM.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $ ELSE !'F$verify(F$trnlnm("SAVE_VERIFY")) $ On_AXP: !'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMBOL.EXE $ $ LINK/NOTRACEBACK/SYSEXE/MAP/FULL'P2' SYMBOL.OBJ,- ! create SYMBOL.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) SYS$INPUT/OPTIONS,SYMBOL.ALPHA_OPT/OPTIONS,VERSION.OPT/OPTIONS SYMCLITBL.OBJ SYMCLUSTER.OBJ SYMDELSETB.OBJ SYMDISPLAY.OBJ SYMFINDLEI.OBJ $ $! Link SYMBOL$AST_LEI.EXE $ $ LINK /NOSYSSHR/NOTRACEBACK/SHAREABLE=SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI - /MAP=SYMBOL$AST_LEI/FULL/CROSS_REFERENCE/SYMBOL_TABLE=SYMBOL$AST_LEI - /NATIVE_ONLY/BPAGE=13/SECTION_BINDING/REPLACE/VMS_EXEC/NODEMAND_ZERO - /SYSEXE=SELECTIVE - SYMBOL$AST_LEI,SYMBOL$AST_LEI.ALPHA_OPT/OPTIONS,VERSION.OPT/OPTIONS $ $! Link SYMLOADER.EXE $ $ LINK/NOTRACEBACK/SYSEXE/MAP/FULL'P2' SYMLOADER.OBJ,VERSION.OPT/OPT ! SYMLOADER.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMUNLOAD.EXE (Development Tool) $ $ LINK/NOTRACEBACK/SYSEXE/MAP/FULL'P2' SYMUNLOAD.OBJ,VERSION.OPT/OPT ! SYMUNLOAD.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) $ $! Link SYMBOLPERM.EXE $ $ LINK/NOTRACEBACK/SYSEXE/MAP/FULL'P2' SYMBOLPERM.OBJ,- ! SYMBOLPERM.EXE 'F$verify(F$trnlnm("BUILD_VERIFY"),F$trnlnm("BUILD_VERIFY")) VERSION.OPT/OPT,SYMBOLPERM.ALPHA_OPT/OPT $ $ ENDIF !'F$verify(F$trnlnm("SAVE_VERIFY")) $ EXIT_RTN: EXIT $STATUS !'F$verify(F$trnlnm("SAVE_VERIFY")) h*[DECUS.SYMBOL]DESCRIP.MMS;1+,H. / 4N J-C0123KPWO56)$ ė7Luė89GHJ#;# MMS file to build SYMBOL for OpenVMS VAX and OpenVMS AXP#F# Written by Hunter Goatley, 17-MAR-1994 10:03 #5# When compiling for OpenVMS AXP, use either MMK or:## $ MMS/MACRO=(__ALPHA__=1)##;.IFDEF EXE # Establish some default file types, depending;.IFDEF __ALPHA__ # ... on which system is being used, etc.MAP = .ALPHA_MAPSTB = .ALPHA_STBOPT = .ALPHA_OPT.ELSE MAP = .MAP STB = .STB OPT = .OPT.ENDIF.ELSE EXE = .EXE OBJ = .OBJ OLB = .OLB MAP = .MAP STB = .STB.IFDEF __ALPHA__OPT = .ALPHA_OPT.ELSE OPT = .OPT.ENDIF.ENDIF=SYMBOL$AST_LEI_IMAGE = SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE#/# Set up the architecture-dependent qualifiers#.IFDEF __ALPHA__SYSEXE = /SYSEXEDLEIQUALS = /NOSYSSHR/NOTRACEBACK/SHAREABLE=$(SYMBOL$AST_LEI_IMAGE) -0 /MAP=SYMBOL$AST_LEI$(MAP)/FULL/CROSS_REFERENCE-% /SYMBOL_TABLE=SYMBOL$AST_LEI$(STB) -G /NATIVE_ONLY/BPAGE=13/SECTION_BINDING/REPLACE/VMS_EXEC/NODEMAND_ZERO - /SYSEXE=SELECTIVE.ELSESYSEXE =DLEIQUALS = /NOSYSSHR/NOTRACEBACK/SHAREABLE=$(SYMBOL$AST_LEI_IMAGE) -0 /MAP=SYMBOL$AST_LEI$(MAP)/FULL/CROSS_REFERENCE-# /SYMBOL_TABLE=SYMBOL$AST_LEI$(STB).ENDIF#)# SYMBOL consists of all of these files.#?SYMBOL : SYMBOL$(EXE),$(SYMBOL$AST_LEI_IMAGE),SYMLOADER$(EXE),-- SYMUNLOAD$(EXE),SYMBOLPERM$(EXE),SYMBOL.HLB !B !SYMBOL built (SYMBOL$AST_LEI.EXE copied to SYS$LOADABLE_IMAGES:) !=SYMBOL_OBJS = SYMBOL$(OBJ),SYMCLITBL$(OBJ),SYMCLUSTER$(OBJ),-6 SYMDELSETB$(OBJ),SYMDISPLAY$(OBJ),SYMFINDLEI$(OBJ)6SYMBOL$(EXE) : $(SYMBOL_OBJS),SYMBOL$(OPT),VERSION.OPT6 $(LINK)$(LINKFLAGS)/NOTRACE$(SYSEXE) $(SYMBOL_OBJS),-* SYMBOL$(OPT)/OPTIONS,VERSION.OPT/OPTIONSC$(SYMBOL$AST_LEI_IMAGE) : SYMBOL$AST_LEI$(OBJ),SYMBOL$AST_LEI$(OPT)) $(LINK)$(LINKFLAGS)/NOTRACE$(LEIQUALS) -5 SYMBOL$AST_LEI$(OBJ),SYMBOL$AST_LEI$(OPT)/OPTIONS,- VERSION.OPT/OPTIONS-SYMLOADER$(EXE) : SYMLOADER$(OBJ),VERSION.OPTI $(LINK)$(LINKFLAGS)/NOTRACE$(SYSEXE) SYMLOADER$(OBJ),VERSION.OPT/OPTIONS-SYMUNLOAD$(EXE) : SYMUNLOAD$(OBJ),VERSION.OPTI $(LINK)$(LINKFLAGS)/NOTRACE$(SYSEXE) SYMUNLOAD$(OBJ),VERSION.OPT/OPTIONS.IFDEF __ALPHA__DSYMBOLPERM$(EXE) : SYMBOLPERM$(OBJ),SYMBOLPERM.ALPHA_OPT,VERSION.OPT8 $(LINK)$(LINKFLAGS)/NOTRACE$(SYSEXE) SYMBOLPERM$(OBJ),-2 SYMBOLPERM.ALPHA_OPT/OPTIONS,VERSION.OPT/OPTIONS.ELSE/SYMBOLPERM$(EXE) : SYMBOLPERM$(OBJ),VERSION.OPTJ $(LINK)$(LINKFLAGS)/NOTRACE$(SYSEXE) SYMBOLPERM$(OBJ),VERSION.OPT/OPTIONS.ENDIF3SYMBOL$(OBJ) : SYMBOL.MAR ! SYMBOL (main routine);SYMDELSETB$(OBJ) : SYMDELSETB.MAR ! /DELETE, /SET, /BINARY-SYMDISPLAY$(OBJ) : SYMDISPLAY.MAR ! /DISPLAY4SYMCLUSTER$(OBJ) : SYMCLUSTER.MAR ! Cluster Support7SYMFINDLEI$(OBJ) : SYMFINDLEI.MAR ! Locate support LEINSYMBOL$AST_LEI$(OBJ) : SYMBOL$AST_LEI.MAR ! SYMBOL$AST_LEI loadable exec image@SYMLOADER$(OBJ) : SYMLOADER.MAR ! SYMBOL$AST_LEI dynamic loaderHSYMUNLOAD$(OBJ) : SYMUNLOAD.MAR ! SYMBOL$AST_LEI dyn. unload (Dev.Tool)<SYMBOLPERM$(OBJ) : SYMBOLPERM.MAR ! Define SYMBOL permanentSYMBOL.HLP : SYMBOL.RNHSYMBOL.HLB : SYMBOL.HLP"*[DECUS.SYMBOL]INSTALL_SYMBOL.COM;1+,I./ 4O-C0123KPWO56 ė7U ė89GHJG$! Copyright 1993, 1994 by Brian Schenkenberger and TMESIS ConsultingJ$!------------------------------------------------------------------------H$! This file should be executed during system startup to install SYMBOL.G$! If SYMBOL was not placed in the directory: SYS$COMMON:[SYSEXE] then,G$! pass the device and directory specification where SYMBOL.EXE resides%$! as a parameter to this procedure. J$!------------------------------------------------------------------------ $ SET NOON$I$ IF .V TMESIS.BCKIC"[DECUS.SYMBOL]INSTALL_SYMBOL.COM;1O=NOT.F$PRIVILEGE("SYSNAM,CMKRNL,SYSPRV") THEN $ GOTO PRIVILEGE_ERROR$3$ IF "''P1'" .EQS "" THEN $ P1:=SYS$COMMON:[SYSEXE]$K$ SYMBOL_EXE_SPEC:= "''F$extract(0,F$locate(";",F$parse("SYMBOL.EXE",P1)),-" F$parse("SYMBOL.EXE",P1))'" $2$ DEFINE/SYSTEM/EXECUTIVE SYMBOL 'SYMBOL_EXE_SPEC'4$ IF "''F$FILE_ATTRIBUTES(SYMBOL_EXE_SPEC,"KNOWN")'"$ THENG$ INSTALL REPLACE/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMKRNL/LOG - 'SYMBOL_EXE_SPEC'$ ELSEC$ INSTALL ADD/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMKRNL/LOG - 'SYMBOL_EXE_SPEC'$ ENDIF$O$ SYMBOLPERM_SPEC:= "''F$extract(0,F$locate(";",F$parse("SYMBOLPERM.EXE",P1)),-& F$parse("SYMBOLPERM.EXE",P1))'" $4$ IF "''F$FILE_ATTRIBUTES(SYMBOLPERM_SPEC,"KNOWN")'"$ THENG$ INSTALL REPLACE/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMEXEC/LOG - 'SYMBOLPERM_SPEC'$ ELSEC$ INSTALL ADD/OPEN/HEADER_RESIDENT/SHARED/PRIVILEGED=CMEXEC/LOG - 'SYMBOLPERM_SPEC'$ ENDIF$ #$ RUN 'F$parse("SYMLOADER.EXE",P1)'$ EXIT$ $ PRIVILEGE_ERROR:M$ IF .NOT.F$PRIVILEGE("CMKRNL") THEN $ WRITE SYS$ERROR "''F$MESSAGE(%x2804)'"M$ IF .NOT.F$PRIVILEGE("SYSNAM") THEN $ WRITE SYS$ERROR "''F$MESSAGE(%x2814)'"M$ IF .NOT.F$PRIVILEGE("SYSPRV") THEN $ WRITE SYS$ERROR "''F$MESSAGE(%x28E4)'"$ EXIT(*[DECUS.SYMBOL]SYMBOL$AST_LEI.ALPHA_MAP;1+,J.$/ 4$#&-C0123KPWO$567689GHJ SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE 30-MAR-1996 15:41 Linker A11-36 Page 1G +------------------------+G ! Object Module Synopsis !G +------------------------+lModule Name Ident Bytes File Creation Date Creatorl----------- ----- ----- ----- ------------- -------nSYMBOL SYMBOL V3%4.091 4084 [000000.SYMBOL]SYMBOL$AST_LEI.OBJ;2 30-MAR-1996 15:41 AMAC V2.2-16nSYS$DOINIT X-3 576 SYS$COMMON:[SYSLIB]STARLET.OLB;3 29-NOV-1995 21:56 AMAC V2.2-09nGLOBALS X-4 0 SYS$COMMON:[SYS$LDR]DCLDEF.STB;1 29-NOV-1995 21:05 AMAC V2.2-09pLIB$MSGDEF X-4 0 SYS$COMMON:[SYSLIB]STARLET.OLB;3 29-NOV-1995 19:40 Message A02-09oSYS$BASE_IMAGE ALPHA X65G-T3A 0 [SYS$LDR]SYS$BASE_IMAGE.EXE;1 29-NOV-1995 23:25 Linker A11-20 SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 2G +------------------------+G ! Image Section Synopsis !G +------------------------+~ Cluster Type Pglts Base Addr Disk VBN PFC Protection and Paging Global Sec. Name Match Majorid Minorid~ ------- ---- ----- --------- -------- --- --------------------- ---------------- ----- ------- -------PAGED_READONLY_PSECTS M 4 7 00000000-R 3 0 READ ONLY EXECUTABLEPAGED_READWRITE_PSECTS N 4 2 00002000-R 10 0 READ WRITE COPY ON REFINITIALIZATION_PSECTS N 4 2 00004000-R 12 0 READ WRITE COPY ON REFP 2 1 00006000-R 14 0 READ WRITE FIXUP VECTORSSYS$BASE_IMAGE 1 90 00000000-R 0 0 READ ONLY EXECUTABLE SYS$BASE_IMAGE_0 EQUAL 34 3832085 1 244 0000C000-R 0 0 READ WRITE COPY ON REF SYS$BASE_IMAGE_0 EQUAL 34 3832085 2 7 0002C000-R 0 0 READ WRITE FIXUP VECTORS SYS$BASE_IMAGE_0 EQUAL 34 3832085$ Key for special characters above: +--------------------+ ! R - Relocatable ! ! P - Protected ! +--------------------+ SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 3H +--------------------------+H ! Program Section Synopsis !H +--------------------------+kPsect Name Module Name Base End Length Align Attributesk---------- ----------- ---- --- ------ ----- ----------. BLANK . 00000000 00000000 00000000 ( 0.) OCTA 4 NOPIC,CON,REL,LCL,NOSHR, EXE, WRT,NOVEC, MOD Q SYMBOL 00000000 00000000 00000000 ( 0.) OCTA 4Q SYS$DOINIT 00000000 00000000 00000000 ( 0.) OCTA 4Q GLOBALS 00000000 00000000 00000000 ( 0.) OCTA 4EXEC$PAGED_CODE 00000000 00000CA3 00000CA4 ( 3236.) 2 ** 5 PIC,CON,REL,GBL,NOSHR, EXE,NOWRT,NOVEC, MOD Q SYMBOL 00000000 00000CA3 00000CA4 ( 3236.) 2 ** 5EXEC$PAGED_DATA 00002000 0000205F 00000060 ( 96.) 2 ** 5 PIC,CON,REL,GBL,NOSHR,NOEXE, WRT,NOVEC, MOD Q SYMBOL 00002000 0000205F 00000060 ( 96.) 2 ** 5EXEC$PAGED_LINKAGE 00002060 0000220F 000001B0 ( 432.) 2 ** 5 PIC,CON,REL,GBL,NOSHR,NOEXE, WRT,NOVEC, MOD Q SYMBOL 00002060 0000220F 000001B0 ( 432.) 2 ** 5EXEC$INIT_000 00004000 00004007 00000008 ( 8.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYS$DOINIT 00004000 00004007 00000008 ( 8.) LONG 2EXEC$INIT_001 00004008 0000400F 00000008 ( 8.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYMBOL 00004008 0000400F 00000008 ( 8.) LONG 2Q SYS$DOINIT 00004010 00004010 00000000 ( 0.) LONG 2EXEC$INIT_002 00004010 00004013 00000004 ( 4.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYS$DOINIT 00004010 00004013 00000004 ( 4.) LONG 2EXEC$INIT_CODE 00004020 000042DF 000002C0 ( 704.) 2 ** 5 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYMBOL 00004020 0000410F 000000F0 ( 240.) 2 ** 5Q SYS$DOINIT 00004120 000042DF 000001C0 ( 448.) 2 ** 5EXEC$INIT_LINKAGE 000042E0 000043AF 000000D0 ( 208.) 2 ** 5 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYMBOL 000042E0 00004327 00000048 ( 72.) 2 ** 5Q  TMESIS.BCKJC([DECUS.SYMBOL]SYMBOL$AST_LEI.ALPHA_MAP;1$  SYS$DOINIT 00004340 000043AF 00000070 ( 112.) 2 ** 5EXEC$INIT_SSTBL_000 000043B0 000043B0 00000000 ( 0.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYS$DOINIT 000043B0 000043B0 00000000 ( 0.) LONG 2EXEC$INIT_SSTBL_001 000043B0 000043B0 00000000 ( 0.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYS$DOINIT 000043B0 000043B0 00000000 ( 0.) LONG 2EXEC$INIT_SSTBL_002 000043B0 000043B3 00000004 ( 4.) LONG 2 PIC,CON,REL,GBL,NOSHR, EXE, WRT,NOVEC, MOD Q SYS$DOINIT 000043B0 000043B3 00000004 ( 4.) LONG 2 SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 4G +------------------------+G ! Symbol Cross Reference !G +------------------------+JSymbol Value Defined By Referenced By ...J------ ----- ---------- -----------------KAMAC$EMUL_CMPC5 00005F50-RX SYS$BASE_IMAGE SYMBOL KAMAC$EMUL_CRC 00005F60-RX SYS$BASE_IMAGE SYMBOL KAMAC$EMUL_LOCC 00005F70-RX SYS$BASE_IMAGE SYMBOL KCTL$AG_CLIDATA 00000B80-X SYS$BASE_IMAGE SYMBOL KCTL$GL_CMSUPR 00000280-X SYS$BASE_IMAGE SYMBOL KCTL$GL_PHD 00000330-X SYS$BASE_IMAGE SYMBOL KCTL$GQ_COMMON 000002D0-X SYS$BASE_IMAGE SYMBOL KCTL$GT_CLINAME 00000B40-X SYS$BASE_IMAGE SYMBOL KEXE$ALONONPAGED 000026C0-RX SYS$BASE_IMAGE SYMBOL KEXE$CONNECT_SERVICES 000029C0-RX SYS$BASE_IMAGE SYS$DOINIT KEXE$DEANONPAGED 00002A10-RX SYS$BASE_IMAGE SYMBOL KEXE$DEANONPGDSIZ 00002A20-RX SYS$BASE_IMAGE SYMBOL KEXE$GL_STATE 00009900-RX SYS$BASE_IMAGE SYS$DOINIT 6INI$A_BUILD_TABLE 000043B0-R SYS$DOINIT 6INI$A_VECTOR_TABLE 00004000-R SYS$DOINIT 6INI$SYSTEM_SERVICE 00004368-R SYS$DOINIT KLIB$_NOCLI 0015837C LIB$MSGDEF SYMBOL 6NSPRV_ROUTINE 00002010-R SYMBOL KOTS$CALL_PROC 00006020-RX SYS$BASE_IMAGE SYMBOL KOTS$MOVE 00006E50-RX SYS$BASE_IMAGE SYMBOL 6PKRNL_ROUTINE 00002008-R SYMBOL KPPD$Q_CLISYMTBL 0000000C GLOBALS SYMBOL KSCH$POSTEF 00004110-RX SYS$BASE_IMAGE SYMBOL eKSCH$QAST 00004120-RX SYS$BASE_IMAGE SYMBOL r6SKRNL_ROUTINE 00002000-R SYMBOL KSYM_B_TYPE 00000020 GLOBALS SYMBOL -KSYM_K_BINARY 00000002 GLOBALS SYMBOL ;KSYM_T_SYMBOL 00000023 GLOBALS SYMBOL KSYM_W_NONUNIQUE 00000021 GLOBALS SYMBOL KSYM_W_PROCLEVEL 00000012 GLOBALS SYMBOL -6SYS$K_VERSION 00000000-X SYS$BASE_IMAGE 6SYS$K_VERSION_01 00000010-X SYS$BASE_IMAGE 6SYS$K_VERSION_02 00000020-X SYS$BASE_IMAGE 6SYS$K_VERSION_03 00000030-X SYS$BASE_IMAGE 6SYS$K_VERSION_04 00000040-X SYS$BASE_IMAGE 6SYS$K_VERSION_05 00000050-X SYS$BASE_IMAGE 6SYS$K_VERSION_06 00000060-X SYS$BASE_IMAGE 6SYS$K_VERSION_07 00000070-X SYS$BASE_IMAGE 6SYS$K_VERSION_08 00000080-X SYS$BASE_IMAGE 6SYS$K_VERSION_09 00000090-X SYS$BASE_IMAGE 6SYS$K_VERSION_10 000000A0-X SYS$BASE_IMAGE 6SYS$K_VERSION_11 000000B0-X SYS$BASE_IMAGE 6SYS$K_VERSION_12 000000C0-X SYS$BASE_IMAGE 6SYS$K_VERSION_13 000000D0-X SYS$BASE_IMAGE 6SYS$K_VERSION_14 000000E0-X SYS$BASE_IMAGE 6SYS$K_VERSION_15 000000F0-X SYS$BASE_IMAGE 6SYS$K_VERSION_16 00000100-X SYS$BASE_IMAGE 6SYS$K_VERSION_17 0000A6F0-X SYS$BASE_IMAGE 6SYS$K_VERSION_18 0000A700-X SYS$BASE_IMAGE  0SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 5ED +------------------+D ! Symbols By Value !D +------------------+2Value Symbols...2----- ----------$00000000 X-SYS$K_VERSION $00000002 SYM_K_BINARY $0000000C PPD$Q_CLISYMTBL $00000010 X-SYS$K_VERSION_01 $00000012 SYM_W_PROCLEVEL =00000020 SYM_B_TYPE X-SYS$K_VERSION_02 $00000021 SYM_W_NONUNIQUE $00000023 SYM_T_SYMBOL $00000030 X-SYS$K_VERSION_03 $00000040 X-SYS$K_VERSION_04 $00000050 X-SYS$K_VERSION_05 $00000060 X-SYS$K_VERSION_06 $00000070 X-SYS$K_VERSION_07 $00000080 X-SYS$K_VERSION_08 $00000090 X-SYS$K_VERSION_09 $000000A0 X-SYS$K_VERSION_10 $000000B0 X-SYS$K_VERSION_11 $000000C0 X-SYS$K_VERSION_12 $000000D0 X-SYS$K_VERSION_13 $000000E0 X-SYS$K_VERSION_14 $000000F0 X-SYS$K_VERSION_15 $00000100 X-SYS$K_VERSION_16 $00000280 X-CTL$GL_CMSUPR $000002D0 X-CTL$GQ_COMMON $00000330 X-CTL$GL_PHD $00000B40 X-CTL$GT_CLINAME $00000B80 X-CTL$AG_CLIDATA $00002000 R-SKRNL_ROUTINE $00002008 R-PKRNL_ROUTINE $00002010 R-NSPRV_ROUTINE $000026C0 RX-EXE$ALONONPAGED $000029C0 RX-EXE$CONNECT_SERVICES$00002A10 RX-EXE$DEANONPAGED $00002A20 RX-EXE$DEANONPGDSIZ $00004000 R-INI$A_VECTOR_TABLE $00004110 RX-SCH$POSTEF $00004120 RX-SCH$QAST $00004368 R-INI$SYSTEM_SERVICE $000043B0 R-INI$A_BUILD_TABLE $00005F50 RX-AMAC$EMUL_CMPC5 $00005F60 RX-AMAC$EMUL_CRC $00005F70 RX-AMAC$EMUL_LOCC $00006020 RX-OTS$CALL_PROC $00006E50 RX-OTS$MOVE $00009900 RX-EXE$GL_STATE $0000A6F0 X-SYS$K_VERSION_17 $0000A700 X-SYS$K_VERSION_18 $0015837C LIB$_NOCLI  RSYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 6 2Value Symbols...2----- ----------$ Key for special characters above: +--------------------+ ! * - Undefined ! ! A - Alias Name ! ! I - Internal Name ! ! U - Universal ! ! R - Relocatable ! ! X - External ! ! WK - Weak ! ! M - Mask value ! +--------------------+ SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 7 C +----------------+ C ! Image Synopsis ! C  GY TMESIS.BCKJC([DECUS.SYMBOL]SYMBOL$AST_LEI.ALPHA_MAP;1$a +----------------+0fVirtual memory allocated: 00000000 00007FFF 00008000 (32768. bytes, 64. pages)AStack size: 0. pages UImage header virtual block limits: 1. 2. ( 2. blocks) UImage binary virtual block limits: 3. 14. ( 12. blocks),PImage name and identification: SYMBOL$AST_LEI SYMBOL V3%4.091;System component mask: 0001303205 SYS$K_VERSION_MEMORY_MANAGEMENT 3,0C5 SYS$K_VERSION_PROCESS_SCHED 2,0(6 SYS$K_VERSION_SYSGEN 1,646 SYS$K_VERSION_STABLE 1,646 SYS$K_VERSION_MISC 1,646 SYS$K_VERSION_SHELL 1,64;Number of files: 5.O;Number of modules: 5.0;Number of program sections: 15.0;Number of global symbols: 30.,;Number of cross references: 73.T;Number of image sections: 7.:User transfer address: 00004340;Number of code references to shareable images: 36. |Image type: PIC, SHAREABLE. Global Section Match=EQUAL, Ident, Major=3, Minor=262289Map format: FULL WITH CROSS REFERENCE in file SYS$TMESIS:[000000.SYMBOL]SYMBOL$AST_LEI.ALPHA_M<Estimated map length: 43. blocksE +---------------------+CE ! Link Run Statistics !E +---------------------+ SPerformance Indicators Page Faults CPU Time Elapsed TimeTS---------------------- ----------- -------- ------------SU Command processing: 121 00:00:00.13 00:00:00.27 U Pass 1: 21 00:00:00.19 00:00:00.44-U Allocation/Relocation: 6 00:00:00.01 00:00:00.10SU Pass 2: 9 00:00:00.16 00:00:00.28MU Map data after object module synopsis: 3 00:00:00.02 00:00:00.03 U Symbol table output: 1 00:00:00.02 00:00:00.22 UTotal run values: 161 00:00:00.53 00:00:01.36X[Using a working set limited to 10240 pages and 2208 pages of data storage (excluding image) 5Total number object records read (both passes): 4300W of which 38 were in libraries and 24 were DEBUG data records containing 24842 bytes6Number of modules extracted explicitly = 11 with 1 extracted to resolve undefined symbols ?0 library searches were for symbols not in the library searchedB4A total of 8 global symbol table records was writtenLINK/EXEC=SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE/NOTRACE/NOSYSSHR/NOTRACEBACK/SHAREABLE=SYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE/MAP=SYMBOL$AST_LEI.ALPHA_MAP/FULL/CROSS_REFERENCE/SYMBOL_TABLE=SYMBOL$AST_LEI.ALPHA_STB/NATIVE_ONLY/BPAGE=13/SECTION_BINDING/REPLACE/VMS_ ASYS$COMMON:[SYS$LDR]SYMBOL$AST_LEI.EXE;3 30-MAR-1996 15:41 Linker A11-36 Page 8_kEXEC/NODEMAND_ZERO/SYSEXE=SELECTIVE SYMBOL$AST_LEI.OBJ,SYMBOL$AST_LEI.ALPHA_OPT/OPTIONS,VERSION.OPT/OPTIONSG(SYS$LIBRARY:STARLET/INCLUDE:(SYS$DOINIT)*ALPHA$LOADABLE_IMAGES:DCLDEF.STB/SELECTIVEGCOLLECT=NONPAGED_READONLY_PSECTS/ATTRIBUTES=RESIDENT,EXEC$NONPAGED_CODES7COLLECT=NONPAGED_READWRITE_PSECTS/ATTRIBUTES=RESIDENT,-0, EXEC$NONPAGED_DATA,EXEC$NONPAGED_LINKAGE-COLLECT=PAGED_READONLY_PSECTS,EXEC$PAGED_CODESACOLLECT=PAGED_READWRITE_PSECTS,EXEC$PAGED_DATA,EXEC$PAGED_LINKAGE >COLLECT=INITIALIZATION_PSECTS/ATTRIBUTES=INITIALIZATION_CODE,-% EXEC$INIT_CODE,EXEC$INIT_LINKAGE,-S. EXEC$INIT_000,EXEC$INIT_001,EXEC$INIT_002,-> EXEC$INIT_SSTBL_000,EXEC$INIT_SSTBL_001,EXEC$INIT_SSTBL_0027GSMATCH=EQUAL,3,%x40091 ! makes GS id reflect version_"IDENTIFICATION = "SYMBOL v3%4.091"X SYS$BASE_IMAGE 6SYS$K_VERSION_08 00000080-X SYS$BASE_IMAGE 6SYS$K_VERSION_09 00000090-X SYS$BASE_IMAGE 6SYS$K_VERSION_10 000000A0-X SYS$BASE_IMAGE 6SYS$K_VERSION_11 0(*[DECUS.SYMBOL]SYMBOL$AST_LEI.ALPHA_OPT;1+,K./ 4GV-C0123KPWO56AX ė7mp ė89GHJ(SYS$LIBRARY:STARLET/INCLUDE:(SYS$DOINIT)*ALPHA$LOADABLE_IMAGES:DCLDEF.STB/SELECTIVEGCOLLECT=NONPAGED_READONLY_PSECTS/ATTRIBUTES=RESIDENT,EXEC$NONPAGED_CODE7COLLECT=NONPAGED_READWRITE_PSECTS/ATTRIBUTES=RESIDENT,-, EXEC$NONPAGED_DATA,EXEC$NONPAGED_LINKAGE-COLLECT=PAGED_READONLY_PSECTS,EXEC$PAGED_CODEACOLLECT=PAGED_READWRITE_PSECTS,EXEC$PAGED_DATA,EXEC$PAGED_LINKAGE>COLLECT=INITIALIZATION_PSECTS/ATTRIBUTES=INITIALIZATION_CODE,-% EXEC$INIT_CODE,EXEC$INIT_LINKAGE,-. EXEC$INIT_000,EXEC$INIT_001,EXEC$INIT_002,-> EXEC$INIT_SSTBL_000,EXEC$INIT_SSTBL_001,EXEC$INIT_SSTBL_002(*[DECUS.SYMBOL]SYMBOL$AST_LEI.ALPHA_STB;1+,L./ 4U-C0123KPWO56<'7/"89GHJUUSYMBOL$AST_LEISYMBOL V3%4.09130-MAR-1996 15:4130-MAR-1996 15:41Linker A11-36  .$$ABS$$. "*[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1+,M.@/ 4P@?2-C0123KPWO@56s.љ7TXՙ89GHJ7 .TITLE SYMBOL ; SYMBOL$AST_LEI (SYMBOL AST routines)5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++J; This is a Loadable Executive Image (LEI) which contains the AST routinesJ; used by SYMBOL. The AST routines are contain in this LEI to provide forJ; a common mechanism for supporting SYMBOL on OpenVMS/VAX and OpenVMS/AXP.;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting8; All rights reserved. ; --------------------!1ty=  ls{ m z@2[ B8=oxON;1 1 ,CIITjbCP(\kv bO$/W nL%JYMkS>*g~KQZ:h@9aRY4Qa"!b?lrR#PV!24x-H:of K/vIIF` :x:Qa32Ne Q5GT~vHf9z?C}|'t^!@4[~Td_~o [Ot9&?F{zN$@QPsq'zGúRwI|gFo:YT'&R]c=$ Y bC>UHMrjc" nqkJ7-4'g2BJ1)r60Y=>>4 -kon*}UYSnL8iJ]k' {JLd)vLFT:Le Pn>,F&h\N0eNGfM1bgi J0*FrD"j{y>Tr-0JE!*72{TEoE`}CbEW{tl _2B}]XEcQsE}tCNs`xV!U[AglVl*v<^ujC(h/=Q]$OT%iFEN0'J/J=_Pe$ Ta4{j8/$- dUE V\lv!!|M9 k3wZ X:!W.JaP/]Rz`cT"Ta^F16FKSj'9)H h()mxS/F+ &;+#!H #wMZv|N IK:#%i11y(e !S:a(#@Tl=3b ' OFV:] ot;H`0uw]4td8FB0Bi +<^n?% D7>ur[RV_bWf >e!w;AK-PbA8>I9M({pI1'&Zp]Qysz7_7`ab\xkmn x+kA57vwk6&a )Y:j@x.GD=4nmm||$ !6)zNwP|xR{DB}NM*(J}m#cmy/EL=>vAA \bY=UL5T];m5VLH BTHqDYl?>7IbE*jsPZ4#6"3OePIGyo1Iz+6Ez(}`|a.l7nm)'d g!WQ< I &`jN $RiSgo,8'c96HOR9V>wH3 Dsh&L(Y*slPoy(["#6F|J 6 Lj\H=qs[{RcNodHAH]),R\_HFh3t'GdZ+<&R[paf f_@|z-1zqb '${sQ$A=<9O5-dc0?c!I4u(VH^W3hF1C xxQR }FFM 2Sm{,fNFL/J2 wi/eA%WTKp^ Rv@?q7sd ]528>d6=%D ! 'i} RSq@h>NA(kO<+<~YBZzTCZ7M;n>F-:s<o; L3W1okkW$v$|bBoS}m:I !{qj7y3nS# u!M,{QY.ucz4RjHkABTwLg:8{]-ht]%m3,5wki_"[,+]w6MBz{pY}AW+;<qL!Dm!:FN >1O Y\( P(!;5>*Gte`&$-1XF%PK.yB1l}wAR@nlݰ&l@0GN+aPG~,[]~n.6F=)w deVH=EX}\^+%jWU.8@#GF6Swz#! ;er-}5$g*Zh75d>52MM,(H%KJ-Q|'bQynF!0h&XR k8R l1p& Z8o'{$% nqRHR5ji?'jE8j-_ b~|:Bv-r@enw`-K.Et)g$]s,Yc fwTQN' m5] N{I|4E54WH'IEh^CS"(lPEYDJ5fyC-0^$pj{0,!k`0J4`e=TmOBC/wee <_@2sn={+"h22s hFa_'Z!%=5ȍ)\y?t>! ~ T",~1*YA#%5l)Xhu0$ݙZHbQ^>JGT,.L w3K/ (qm;-y @`{^28Or}aaHGXb!_A1DD&'jrRIwo"@52+ Zft02Ohz>+~:=9T9 ~Gu|!v`g4C.2(uTaB#_$LDN^v]X~ :"~< x`df)-w_i)?M4:UHDO1q2^ DQJ'W:IY tu 8p5S7To$Uh[8 chXe})!7('tSfYgwm-*+bg; kjzFyedt/|Pu0?FmMA @:_\ '~tmtq/L.X$?0[Oj}-Y4q]K\k $o2B6#ivO]B(LucYX.WT\*"63"\g5KF,? 59[`-cJ!gCRwu `_1J MNA&n4/m`DK {+;g[ XQCWrC[\BgyGA F{ 2^*3nQ JT^lN?#i^GAjMu(HsZxx%s Q^sth*et%>(N$:W>h{R){wHG09FM Wz\c P,xk~^*~Wd$ZGXU Ky *[Hx!DK UIF;9,'{Fxu Ey$,om=w\LE'rbSKIx)Xf[3 /T{y_}`rFDKZ7 d^5QwS<6U2Q slv=a6;D+5ghI3 PMeX[H VZV5o1Q C$n{|9_z`5\' sH0CPF\Kc;>o4k#Sx[`xe2OCcue4+}>KA`tLVKqHK<A2z% 7q_HrnKsg#ZtQb &Fz`.o5[?jh-RQij6VEn`t2(9cd1&xDVRoFaC-/Y{t4^s)(zGH|=+L]=8 &BFnC;/p|c rlRh[H C#&MF}!jDyunImdW|_*ND?l;3 h(oZrwyyGDE/a?HC#G~M1LTJyn)o*W>*ks;Q 4hG+|SK@`^A " G Lty^d[-j?/g)hu\#X7l56F> >T:q"pGYX zOPH9a}2)X!qd):XigWq@?kTKp3"}8cO&M6U<_,%$kqVWx(&XX+d5FOg~3pRYpV&?N`c -L\Q02OTF7b|t;]uX F2u-u9cpmj+ke4,5h5?y<QPv;8t~1f_ @k^Bk>|vh9#:)-Mf;_kP])}CQVdlWu=J}tEN[PD!ip>r9+ ] 7 m\AGY>:oU W D88Nu2\F{]3n;M~=%JC9jB[2uB &K$ (=eHc1B i\A3G=\/kXBmK?g 5qu.d),\E-Kz7ri Pj %JGUz߹w"U~hRVyCPIbkBY.(pxcin%@\Qii()sKA1(yq2N/b8[R-%aZG6|0`g"0T,uqlg&b^$~^+?[-r3e6,I=!bC~s!_7x&'rH<{xm` @S[C+E ~hI{pLi:s 4Zh!sw-rrl`'!A2 `,{a"f2Y1< Ee0EF6h<.Jcv:Ev 9=PSV,IZ9*@^"A())?lS m2_Tr$1jGtU=i2`crgEF@w 6^d`eWZ_bYh81'49wo1:C]&,mq-S[y-q/zw6q1Yv3R7HItw#8mf|#'Sf0gu;OSp&L{qGg)e.TK= %,klF v!4,%Ada:N$^sko ZV4=8)13n]i Tg X ;faz.Kp|>S[XAYB|&lz*OXi+T!lh4B.}xiE9"^5 X  Gx(M+?0Z;h+0Vj~Bg8;%grv3TC,z3d'"%uJ:o(|i"!fI +Ó=tqMPeaBbr+*Y` st1uStG&To (Ex@@C']7 l0,L1Zg]l3Qs5K*QbX IuAA`nmd.78` "nNksm90Z,Ky+q!mt:n$#uCu))W?lLKNAZ}[7vkK*| vKW,;>WU8iHw!hlTGCzl!Jn[L;A,hWK7^8r ?>0 \/ FnX) '* C6gUB\',hOd`Nw@P8:?=v~|5zWr~virXCj{6W_ CKD#%qx*Bkx?_~jsJk9G>8nr^0\qxdL+01+)qZaeGZ?z{*u|\bJ0q:`e=m15LK` ;FS/gp7#$v<2d+rFSD>vd00\r(CGgaUVqaZS|xyr\##;q@ r%POyb`i4a`v$| jK~-n+0sx#H3@%h:l7`WrT!1@"c^oG˃vhd:xiqdΨX ?<@5PUW r&#qW =|m*=G lRDkFuP4M~mP:&_EA8l92LhOcC$q+@%Z HJ DBh)@S^[PPDau,J^2GA2"wH6.m#k+f]L7!Kd),"%@ J*j@=&;ItKT~jj.bZdzv;o[MJ&'kmJ?]4Y6 gg.Y{~QbF# [ 01m>F#U|rTC!;bC VXx ?E;\FOH];-eZ'7YD as+Ch{Y$x_(%[|yz;)tHUWK zx9 O'#:d#Mdb <5v7X=ly-?: =GH1nw:_7ds&`ApqFP#a#Vsy%ppMʼ4M}-uJ!3-wKOZov6O] K^j{CmK ;/ kS~W(}:LEyV[soC1\ A|Zc0X*/{o E%|eI$\7 /&8Z?tSA:D#r(X#Bp#h!MmVboO5`GiRU1P8r~m,oil l'9`YGEFubW}exK[EFkajtp0Ov -7icM+@YC-Z~;.$is4S;4]@2 _X o"qEL;J_ f@Wgaqy}Im+>/[f|B04I/yvv.TUp$xnj>^ARqc7D:jtJwaqa/8U]Ee?q`p #"AY*B{z17hw O-of_ cN 1 $]JG(H-a (BBH2.4UVMH*lit=+~wxOS{/1*+w%!!yvr<wP!D7j;tMce}kJOUAbRZVq.WDONGI'BLVAOpD|%Jsl _1^QvR*0O#{.~POFe I6^RK)Z/V"3D0cc^StrpVtWUSRNw3r DM1QRQ($t4194Io;4T2νS]"bB!_R_R)E#Q`uPd1rp9klq.jzKyGn,<;P-OgB<!nI#gN\SgQx{`>,ddPp2 Fr\Pw4QA{147yA9ERRfzm"v06J5\!%UO.O5Q/VTj!~$91x?7|l&5L@k.<W^jlTYPfj vO'f$qOdFQpj :7/:5"Xh#CM-%hsSpBg>6# .T& CE'#ROe just a MAP fi" TMESIS.BCKMC"[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1P@----M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:; 24-FEB-1994: Created.L; 01-APR-1994: added routine to compute dispatcher's offset for OpenVMS AXP.;-- .SBTTL DECLARATIONS; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly# $ACBDEF ; AST control block def's( $DYNDEF ; dynamic data structure codes1 $PCBDEF ; Process control block structure def's& $PHDDEF ; Process header block def's" $PRIDEF ; process priority def's. $PRVDEF ; Processor privilege quadword def's1 $PSLDEF ; Processor status longword field def's% $CLIDEF ; CLI service request codes% $CLIMSGDEF ; CLI error message codes( $CLISERVDEF ; CLI interface definitions+ $SSDEF ; system service error definitionsM;----------------------------------------------------------------------------1 .SBTTL XDELTA DEBUGGER OPTIONAL BREAKPOINT MACRO;;; XDELTA_DEBUG = 1 .MACRO XDELTA_BREAKPOINT$ .IIF DF,XDELTA_DEBUG, JSB G^INI$BRK .ENDMM;---------------------------------------------------------------------------- .SBTTL SYMBOL ACB extentions ;++K; Relative offset definitions for data extentions common to SYMBOL DISPLAY,1; SYMBOL SET and SYMBOL DELETE kernel mode ASTs. ;--" $OFFSET ACB$K_LENGTH,POSITIVE,<- . ,- ; start of kernel AST data area5 ,- ; event flag to set when ASTs complete3 ,- ; adr of original process status arg/ ,- ; image count at time of request2 ,- ; UIC/access mask to target process- ,- ; size of kernel AST data area > ;++L; Relative offset definitions for eXtended kernel mode data requirements of %; the SYMBOL DISPLAY kernel mode AST.;-- $OFFSET K_SIZE,POSITIVE,<-8 ,- ; start of kernel AST eXtention data area: ,- ; adr of buffer on origin process p0 space= ,- ; SYMBOL Table descriptor of target process1 ,- ; SYMBOL Table descriptor size 3 ,- ; SYMBOL Table descriptor address5 ,- ; Non-paged pool buffer descriptor 9 ,- ; Non-paged pool buffer descriptor size< ,- ; Non-paged pool buffer descriptor address, ,- ; offset to symbol table copy" ,- ; size of this area >;++N; Relative offset definitions for the normal supervisor mode data requirementsP; of SYMBOL SET and SYMBOL DELETE piggyback special-K and supervisor mode ASTs. ;-- $OFFSET K_SIZE,POSITIVE,<-0 ,- ; start of superv. AST data area/ ,-; CLI callback block + ,- ; storage for binary value2 ,- ; CLI function to be performed ) ,- ; symbol listhead address' ,- ; offset to symbol info# ,- ; size of this area >;++K; Relative offset definitions for storage cells which contain the addressesK; of the AST routines in the paged writeable segment of the SYMBOL$AST_LEI.;-- $OFFSET 0,POSITIVE,<- ,- ,- ,- >M;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;---------------------------------------------------------------------------- .SBTTL INITIALIZATION ROUTINE DECLARE_PSECT EXEC$INIT_CODE5 INITIALIZATION_ROUTINE SYMBOL_INITIALIZATION_ROUTINESYMBOL_INITIALIZATION_ROUTINE:' .IIF DF,ALPHA, .CALL_ENTRY OUTPUT=# MOVAL SPECIAL_KERNEL,SKRNL_ROUTINE# MOVAL PIGGYBACK_KAST,PKRNL_ROUTINE# MOVAL SUPERVISOR_AST,NSPRV_ROUTINE .IF DF ALPHA;++G; This routine was created to locate (automatically) and calculate the F; offset to the dispatcher's procedure descriptor. The offset to the D; dispatcher's STacK FRaMe Procedure DeSCriptor is different for theF; versions V1.5, V2.0-FT3 and V2.0-FT4. This value will, most likely,7; be unstable in future releases as well. Therefore...;F; This routine finds the linkage section for DCL$CHANGE_MODE which, onF; AXP, is the STacK FRaMe Procedure DeSCriptor for DCL$CHANGE_MODE andE; is pointed to by CTL$GL_CMSUPR. This routine scans the next ^x1000F; bytes looking for other STacK FRaME Procedure DeSCriptors. When oneG; is located, its entry address is subtracted from the entry address ofF; of DCL$CHANGE_MODE. The calculated "SPAN" is compared with previousF; saved "SPANs" and, the lowest "SPAN" and its associated STacK FRaMe F; Procedure DeSCriptor address are saved. The dispatcher displacement6; is calculated and stored when the routine completes.;F; The theory being: The dispatcher's entry address will be very closeF; to that of the DCL$CHANGE_MODE entry. Scanning the linkage section,G; as described in the previous paragraph, should be able to locate the G; STacK FRaMe Procedure DeSCriptor of the dispatcher routine by looking@; for the entry address closest to the entry of DCL$CHANGE_MODE.;-- 2 $PDSCDEF ; OpenVMS AXP Procedure descriptor def's< STK_FRM_PDSC = QUADWORD = 8 SCAN_REGION = ^x1000; MOVL @#CTL$GL_CMSUPR,R1 ; get DCL$CHANGE_MODE PDSC address; MOVAL SCAN_REGION(R1),R3 ; calculate end of address region< MOVL PDSC$Q_ENTRY(R1),R2 ; get DCL$CHANGE_MODE code address MNEGL #1,R5A10$: MOVAL PDSC$K_MIN_STACK_SIZE(R1),R1 ; move past required part820$: CMPW (R1),#STK_FRM_PDSC ; start of a STK_FRM_PDSC ?% BNEQ 30$ ; nope! try next location> SUBL3 R2,PDSC$Q_ENTRY(R1),R0 ; calc span difference from base, BLSS 30$ ; branch if .lt. base or S0 adr.1 CMPL R0,R5 ; compare with last span difference) BGTRU 30$ ; branch if not the smallest( MOVL R0,R5 ; save new span difference, MOVL R1,R4 ; save address of STK_FRM_PDSC@30$: ACBL R3,#QUADWORD,R1,20$ ; move adr. to next QW, try again.# ; (PDSC's must be QW aligned.)< SUBL3 @#CTL$GL_CMSUPR,R4,- ; calc. and store the adr of the) DISPATCHER ; dispatcher's STK_FRM_PDSC .IF_FALSE;++I; For OpenVMS VAX, the value the DISPATCHER is the number of bytes neededI; to bypass the access mode check instruction which is 8 bytes in length.;-- MOVL #8,DISPATCHER .ENDC1 MOVL #SS$_NORMAL,R0 ; signify success to caller .IF DF ALPHA. RET ; init routine is CALLed on OpenVMS AXP .IF_FALSE- RSB ; init routine is JSBed on OpenVMS VAX .ENDCM;----------------------------------------------------------------------------$ .SBTTL PAGED/WRITEABLE DATA SEGMENT DECLARE_PSECT EXEC$PAGED_DATASKRNL_ROUTINE:: .LONG 0 .LONG 0PKRNL_ROUTINE:: .LONG 0 .LONG 0NSPRV_ROUTINE:: .LONG 0 .LONG 0DISPATCHER: .LONG 0 .LONG 0EAUTODIN:.LONG ^x00000000,^x1DB71064 ; Autodin-II CRC polynomial table> .LONG ^x3B6E20C8,^x26D930AC ; -------------------------------? .LONG ^x76DC4190,^x6B6B51F4 ; used to calculate a hash value? .LONG ^x4DB26158,^x5005713C ; for the symbol to determine an@ .LONG ^xEDB88320,^x#sA TMESIS.BCKMC"[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1P@rF00F9344 ; index to the symbol table list-? .LONG ^xD6D6A3E8,^xCB61B38C ; head where the symbol's (SYM) = .LONG ^x9B64C2B0,^x86D3D2D4 ; block will/should be queued.> .LONG ^xA00AE278,^xBDBDF21C ; -------------------------------M;---------------------------------------------------------------------------- DECLARE_PSECT EXEC$PAGED_CODED .SBTTL PAGED/READ_ONLY - SYMBOL DELSET PIGGYBACK SPECIAL KERNEL AST;++K; This routine is executed as a piggyback special kernel AST (at supervisorM; access mode) in the context of the target process. After performing accessL; checks, this routine copies the CLI callback data needed by the supervisorP; AST into the "user core-common area" where the supervisor AST can access it. ;--J; NOTE: This routine will 'trash' the current contents of the per-process; user "core-common" area.;--PIGGYBACK_KAST:4 .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINT BICL3 UICMSK(R5),-, PCB$L_UIC(R4),R2 ; check if privies are ok+ BEQL 20$ ; privilege is ok. next check.2 MOVL #SS$_NOWORLD,R0 ; assume world priv needed!4 EXTZV #16,#16,R2,R2 ; was it outside group access?+ BNEQ 30$ ; tell originator NOWORLD if so9 MOVL #SS$_NOGROUP,R0 ; obviously outside member access!( BRB 30$ ; tell the originator NOGROUP.20$: MOVL #LIB$_NOCLI,R0 ; assume no DCL cli> IFNORD #4,@#CTL$GT_CLINAME,30$ ; is CTL$GT_CLINAME readable?C CMPV #8,#24,@#CTL$GT_CLINAME,#^a/DCL/; is DCL (or variant) mapped?' BNEQ 30$ ; no... return error NOCLI6 MOVAB @#CTL$AG_CLIDATA,R1 ; base of cli data region3 TSTL PPD$Q_CLISYMTBL(R1) ; get symbol table descr.& BEQL 30$ ; no... return error NOCLI2 BSBW VALID8 ; validate for symbol CLI conflicts BLBC R0,30$8 MOVL #,R3 ; fixed ASTRTN data length...? ADDL2 CALBCK+CLI$Q_NAMDESC(R5),R3 ; plus symbol name length...= ADDL2 CALBCK+CLI$Q_VALDESC(R5),R3 ; plus symbol value length 8 MOVAB @#CTL$GQ_COMMON,R1 ; common are size and base adr0 SUBL3 (R1)+,(R1),R1 ; start of data in process! PUSHL R5 ; preserve adr of ACB4 MOVC3 R3,S_DATA(R5),(R1) ; copy SUPERVISOR ast data POPL R5 ; restore adr of ACB' MOVL #SS$_NORMAL,R0 ; signify success BRB 40$;++L; Use the existing ACB and fill ACB's fields with the originating process's F; IPID and the R0 status to reflect the reason for success or failure.;--<30$: MOVAB @#CTL$GQ_COMMON,R1 ; common are size and base adr0 SUBL3 (R1)+,(R1),R1 ; start of data in process CLRQ (R1)A40$: MOVL ACB$L_ASTPRM(R5),ACB$L_PID(R5) ; move originator's PID 5 MOVL R0,ACB$L_ASTPRM(R5) ; put rtn status in ASTPRM; MOVB #ACB$M_KAST,ACB$B_RMOD(R5) ; queue as a Special-K AST? MOVAB DELSET_ORIGIN,ACB$L_KAST(R5) ; adr of DELSET origin code- CLRL ACB$L_AST(R5) ; no normal AST routine( MOVL #PRI$_TICOM,R2 ; give biggy boost0 JSB G^SCH$QAST ; queue AST to original process RSBM;----------------------------------------------------------------------------A .SBTTL PAGED/READ_ONLY - SYMBOL DELSET SPECIAL KERNEL RETURN AST;++H; This routine is executed as a special kernel AST in the context of theH; the originating process. The routine sets the event flag and returns; the status of the operation.;--DELSET_ORIGIN:1 .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINT3 MOVL @#CTL$GL_PHD,R3 ; get adr of p1 PHD mapping? CMPL PHD$L_IMGCNT(R3),SANITY(R5) ; compare image cnt w/ sanity% BNEQ 10$ ; forget it! dismiss AST? MOVL ACB$L_ASTPRM(R5),@STSADR(R5) ; return status of NPP alloc4 MOVL ACB$L_PID(R5),R1 ; originating process's IPID CLRL R2 ; no prio. boost3 MOVL EF_NUM(R5),R3 ; event flag number to be set! JSB G^SCH$POSTEF ; -- do it --)10$: MOVL R5,R0 ; move ACB's adr to R08 JSB G^EXE$DEANONPAGED ; return to NPP (ACB and code) RSB M;----------------------------------------------------------------------------E .SBTTL PAGED/READ_ONLY - VALIDATE - SYMBOL DELSET SUPPORT SUBROUTINE;++J; This routine will validate the specified symbol based on the function to; be performed to determine:F; a) if it will cause an abbreviate symbol conflict for definition, or-; b) if the symbol is undefined for deletion.M; If the symbol contains an '*' for an abbreviated symbol definition, the '*'K; is removed and then, the LOOKUP routine is invoked. Upon return from theK; LOOKUP routine, if the symbol had contained an '*', it is replaced before; returning to the caller.;--VALID8:: .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINT< ASSUME CLI$K_DEFLOCAL EQ 2 ;^b0010 ; assuptions for several< ASSUME CLI$K_DEFGLOBAL EQ 3 ;^b0011 ; bit test instructions; ASSUME CLI$K_DELELCL EQ 11 ;^b1011 ; ( BBx and BLBx ) used: ASSUME CLI$K_DELEGBL EQ 12 ;^b1100 ; in the CONFLICT code ; 3210 ;: .IIF NDF,ALPHA,PUSHR #^m; save trashed reg's< MOVL CALBCK+CLI$Q_NAMDESC(R5),R7 ; move symbol length to R7. MOVAB SYMINF(R5),R8 ; move symbol adr to R80 BBC #3,FUNCTN(R5),10$ ; is this a define func?) BSBB LOOKUP ; LOOKUP with '*' in name BRB 30$ ; the return adr-10$: LOCC #^a/*/,R7,(R8) ; abbrev. symbol??) PUSHAB -(R0) ; 1 byte shorter w/o '*' BLSS 20$ ; was no '*'" DECL R7 ; new length of symbol' PUSHL R5 ; save movc3 trashed reg's+ MOVC3 R0,1(R1),(R1) ; shorten the string! POPL R5 ; restore saved reg's$20$: BSBW LOOKUP ; try to find it POPL R1 ; was symbol abbrev? BGEQ 40$ ; yeap... fix it up@30$: .IIF NDF,ALPHA,POPR #^m; restore trashed reg's RSB ; done here+40$: SUBL2 R1,R7 ; calc. starting offset' PUSHL R0 ; save movc3 trashed reg's7 MOVC3 R1,(R8)[R7],1(R8)[R7] ; move string back 1 byte! POPL R0 ; restore saved reg's( MOVB #^a/*/,(R8)[R7] ; insert the '*' BRB 30$ ; done here.M;----------------------------------------------------------------------------C .SBTTL PAGED/READ_ONLY - LOOKUP - SYMBOL DELSET SUPPORT SUBROUTINE;++L; This routine uses the symbol (defined by reg's R4: length, R5: address) toM; determine if it exists for symbol delete functions and/or if it would causeH; an abbreviated symbol definition conflict for symbol define functions.;--LOOKUP:: .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINT0 CRC AUTODIN,#-1,R7,(R8) ; calc the hash value - BICL2 #^C^XFF,R0 ; calc the listhead index7 MOVAB @#CTL$AG_CLIDATA,R1 ; base of cli data region= MOVAQ @PPD$Q_CLISYMTBL+4(R1)[R0],R6 ; get the assoc listhead/ MOVL R6,SLHEAD(R5) ; save for SET_BINARY rtn0 BBS #3,FUNCTN(R5),50$ ; is this a delete func?;++*; Logic for the define callback functions ;--210$: MOVL (R6),R6 ; walk the list of SYM blocks* CMPL SLHEAD(R5),R6 ; end of the line??? BEQL 40$ ; quit if at end.5 MOVAB SYM_T_SYMBOL(R6),R1 ; get ascic symbol adress' MOVZBL (R1)+,R0 ; extract the length0 CMPC5 R0,(R1),#0,R7,(R8) ; is this our symbol?& BNEQ 10$ ; better luck next round.2 TSTW SYM_W_NONUNIQUE(R6) ; is the symbol unique?" BGEQ 10$ ; branch if unique... 4 TSTW SYM_W_PROCLEVEL(R6) ; is it a gbl/lcl symbol?0 BLBC FUNCTN(R5),20$ ; is this a lcl sym func?! BGEQ 10$ ; global symbol test BRB 30$ $20$: BLSS 10$ ; local symbol test030$: MOVL #CLI$_ABSYMD,R0 ; return with ABSYMD RSB /40$: MOVL #SS$_NORMAL,R0 ; return with NORMAL RSB;++*; Logic for the delete callback functions ;--250$: MOVL (R6),R6 ; walk the list of SYM blocks* CMPL SLHEAD(R5),R6 ; end of the lin$ TMESIS.BCKMC"[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1P@ e??? BEQL 70$ ; quit if at end.5 MOVAB SYM_T_SYMBOL(R6),R1 ; get ascic symbol adress' MOVZBL (R1)+,R0 ; extract the length0 CMPC5 R0,(R1),#0,R7,(R8) ; is this our symbol?& BNEQ 50$ ; better luck next round.2 TSTW SYM_W_NONUNIQUE(R6) ; is the symbol unique?& BLSS 50$ ; branch if not unique... 4 TSTW SYM_W_PROCLEVEL(R6) ; is it a gbl/lcl symbol?0 BLBS FUNCTN(R5),60$ ; is this a lcl sym func?! BGEQ 50$ ; global symbol test BRB 40$ $60$: BLSS 50$ ; local symbol test BRB 40$ 070$: MOVL #CLI$_UNDSYM,R0 ; return with UNDSYM RSBM;----------------------------------------------------------------------------E= .SBTTL PAGED/READ_ONLY - SYMBOL DELSET NORMAL SUPERVISOR ASTr;++eJ; The supervisor mode AST completes the building of the callback block andI; then invokes the handler normally called by the CHMS to dispatch to the '; handler of the requested CLI service.g; H; The supervisor mode AST invokes code in the routine DCL$CHANGE_MODE inG; the DCL module, HANDLE. This code is pointed to by the P1 space cello<; CTL$GL_CMSUPR. Inputs to the routine DCL$CHANGE_MODE are:;a; for OpenVMS/VAX:A; (SP) - Change mode argument (CLI callback field CLI$W_SERVCOD)uA; 4(SP) - PC of the next instruction after the CHMS instruction. >; 8(SP) - PSL at the time the CHMS instruction was executed. ;t; for OpenVMS/AXP:A; R16 - Change mode argument (CLI callback field CLI$W_SERVCOD)-;-G; The DCL$CHANGE_MODE is currently coded to only handle requests (CHMS)hH; from user mode. The first function of the handler routine performs isI; a check to determine mode from which the routine was invoked to insure fI; that it was indeed invoked from user mode. If the mode checks out, theL+; the dispatch service routine is executed:D; ; for OpenVMS/VAX:4; via a CASEx instruction in the dispatch handler. ; ; for OpenVMA/AXP:1; via a CALL to and internal CASE driven routine.b; G; The supervisor mode AST completes the building of the callback block.gG; It then moves the address of the callback block to register R9. (The$F; CLI callback vector routine stores the address of the callback block9; in R9 before invoking the CHMS instruction.) It then:;;s; for OpenVMS/VAX:9; builds a 'fake' CHMS exception stack frame specifying -; the following:-;-C; .-------------------------------------------------------------.AH; | CLI$K_DEF{GLOBAL/LOCAL}/DELE{GBL/LCL} ; field CLI$W_SERVCOD |:(SP)C; |-------------------------------------------------------------|-J; | The address of the RET instruction in the SUPR AST routine. |:4(SP) C; |-------------------------------------------------------------|LI; | PSL signifying: CURMOD= and PRVMOD= |:8(SP)IC; `-------------------------------------------------------------'>;;; for OpenVMS/AXP:D; computes the address of the Procedure Descriptor for the internalB; dispatcher routine and calls the routine with the value from theE; CLI$W_SERVCOD field of the CLI callback block as its only argument.S;aJ; The routine obtains the address of the DCL$CHANGE_MODE routine from the =; P1 cell CTL$GL_SUPR and stores it in R0. The routine then:; ; for OpenVMS/VAX:E; JMPs 8 bytes into the routine to bypass caller's access mode check. D; The instruction sequence for the check follows. This sequence hasD; not changed from OpenVMS/VAX v4.0 and is valid through the current; version, OpenVMS/VAX v6.0.; ; DCL$CHANGE_MODE::Y.; BBS #PSL$V_CURMOD,8(SP),10$ ; 5 inst. bytes#; BRW DCL$RESTART ; 3 inst. bytes; 10$: BSBW ... ; E; This instruction sequence can be seen by using the following SYSTEMo; DUMP ANALYZER (SDA) commands:T;P:; SDA> examine/instruction @ctl$gl_cmsupr;8 dispatcher2; 7FF56BC8: BBS #18,08(SP),7FF56BD0 ; ---. offset); 7FF56BCD: BRW 7FF564D9 ; | 8 bytesu!; 7FF56BD0: BSBW 7FF55F96 ; <--'L;L; for OpenVMS/AXP:E; calls an internal dispatcher routine to bypass caller's access modeSE; check. The PDSC for the routine is located from the address in the-F; CTL$GL_CMSUPR cell which points to the PDSC for the DCL$CHANGE_MODE E; routine. (Also, its linkage section.) The PDSC for the dispatcherbE; routine (an internal routine in DCL$CHANGE_MODE) can be located offZE; this address. The offset was obtained from the linkage section re- E; port in the source listing [V15.DCL.LIS]HANDLE.LIS. (excerpt below)nE; Fortunately, this internal routine is defined with the .CALL_ENTRY,PE; yeilding a heavyweight frame invocation descriptor, which means it U; can be easily called!-J; NOTE: This offset is now calculated in the LEI's initialization routine.; A;(OpenVMS AXP V1.5) .PSECT $LINKAGE, OCTA, NOPIC, CON, REL, LCL,-.; NOSHR, NOEXE, RD, NOWRT; [... lines ommitted ...]6; 0000 ; Heavyweight Frame invocation descriptor(; Entry point: DCL$CHANGE_MODE'; Registers saved: R3, R13, FPO; Fixed Stack Size: 48"; 0020 .LINKAGE DCL$RESTART"; 0030 .LINKAGE CLI$GET_PRC!; 0040 .LINKAGE DCL$LOADFP,; 0000E000 0050 .LONG 57344K; [... lines ommitted ...]; dispatcher=; offset --> 03E0 ; Heavyweight Frame invocation descriptor ; Entry point: 5_30$0; Registers saved: R2-R8,R10,R13,R15,FP; Fixed Stack Size: 128$; 0400 .LINKAGE AMAC$EMUL_RET%; 0410 .LINKAGE EXE$PROBER_DSCo&; 00000000 0420 .ADDRESS 5_30001$!; 0430 .LINKAGE SYS$DCLASTl ; 0440 .LINKAGE OTS$DIV_L ; 00038822 0450 .LONG 231458 ; 000388CA 0454 .LONG 231626"; 02100000 0458 .LONG 34603008"; 0460 .LINKAGE DCL$SEARCHT&; 00000000 0470 .ADDRESS DCL$CRLF!; 0480 .LINKAGE DCL$SPAWN2h!; 0490 .LINKAGE DCL$SEARCH $; FFFF0000 04A0 .LONG 4294901760 ; 000A0000 04A4 .LONG 655360!; 04B0 .LINKAGE SYS$CRELNMe;yH; When the symbol setting routine completes, control returns back to theH; AST routine, still in supervisor mode, where the SET_BINARY subroutineF; is called. If the /BINARY qualifier was not present in the command,H; the routine simply returns. If the qualifier was present, the routineI; uses the symbol string and the associated listhead. (The hash value of aH; the symbol (CRC/Autodin-II) is calculated in the Special-K AST. It isI; then divided by the number of hashtable listheads (256). The remainderMI; is used to locate the associated listhead.) The routine walks the listrK; of SYM blocks looking for the associated block. If the symbol is found, MI; the binary value over writes the current string value and its type is -H; set to BINARY. The ascii equivalent of the numeric value is used whenH; creating the block so that _if_ the SET_BINARY should fail to find theI; associated SYM block, the symbol will have the string equivalent of theIJ; numeric value. Execution then returns back to the AST delivery routine.;--$SUPERVISOR_AST:a .IF DF ALPHA,# .CALL_ENTRY MAX_ARGS=1,OUTPUT=E .IF_FALSE e* .WORD ^m .ENDCXDELTA_BREAKPOINT_8 MOVAB @#CTL$GQ_COMMON,R2 ; common are size and base adr0 SUBL3 (R2)+,(R2),R2 ; start of data in process@ MOVAB (R2),R9 ; routine looks for callback in R9( TSTL (R9) ; any function specified???% BEQL 20$ ; nope... exit gracefully02 MOVAB (R2),- ; put symbol name adr+ CLI$Q_NAMDESC+4(R9) ; into callback blockO - ADDL3 CLI$Q_NAMDESC(R9),- ; calculate adr ofC- CLI$Q_NAMDESC+4(R9),- ; symbol value stringR- CLI$Q_VALDESC+4(R9) ; put in callback bloc%# TMESIS.BCKMC"[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1P@9/kT; MOVL @#CTL$GL_CMSUPR,R0 ; get DCL$CHANGE_MODE handler adr.p& BEQL 20$ ; no CLI mapped in process2 ADDL2 DISPATCHER,R0 ; calc adr of the dispatcher .IF DF ALPHAtA MOVZWL CLI$W_SERVCOD(R9),-(SP) ; establish the requested service ; ***** HACKing on... *****/ CALLS #1,(R0) ; call the dispatcher directlyi! ; ***** HACKing off... ***** .IF_FALSE$ PUSHL #!-0 ; 'fake' saved PSL, PUSHAB 10$ ; REI back to this AST routineA MOVZWL CLI$W_SERVCOD(R9),-(SP) ; establish the requested serviceA ; ***** HACKing on... *****, JMP (R0) ; jump into dispatcher directly ! ; ***** HACKing off... *****  .ENDC/10$: BSBB SET_BINARY ; call set binary routine0020$: MOVL #SS$_NORMAL,R0 ; don't make DCL barf.* RET ; dirty deed done (dirty cheap :-)M;----------------------------------------------------------------------------aD .SBTTL PAGED/READ_ONLY - SET_BINARY - SYMBOL SET SUPPORT SUBROUTINE;++OK; This routine will define a binary (integer) symbol. The block into whichEK; the integer value will be place is first created as a string symbol block4M; and then this routine locates the block and modifies it accordingly. If -K; the symbol is not to be defined as a binary, the function value stored at-M; FUNCTN-S_DATA will not be negative. In this case, the routine simply RSBs. ;--B SET_BINARY:G4 .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINTc8 MOVAB @#CTL$GQ_COMMON,R9 ; common are size and base adr0 SUBL3 (R9)+,(R9),R9 ; start of data in process8 TSTL (R9) ; should the symbol be binary? BGEQ 30$ ; nope... return...t= MOVQ (R9),- ; move symbol descr. R6 ; to R6:R7( LOCC #^a/*/,R6,(R7) ; abbrev. symbol? BEQL 10$ ; not abbreviated$ DECL R0 ; 1 byte shorter w/o '*'$ DECL R6 ; 1 byte shorter w/o '*'3 MOVC R0,1(R1),(R1) ; move remaining string up...U=10$: MOVL (R9),R8 ; save for end-of-list test 220$: MOVL (R8),R8 ; walk the list of SYM blocks3 CMPL (R9),R8 ; end of the line???6 BEQL 30$ ; quit if at end.5 MOVAB SYM_T_SYMBOL(R8),R1 ; get ascic symbol adressV' MOVZBL (R1)+,R0 ; extract the lengthm0 CMPC5 R0,(R1),#0,R6,(R7) ; is this our symbol?& BNEQ 20$ ; better luck next round.9 MOVL (R9),(R1) ; move in the binary valueT; MOVB #SYM_K_BINARY,SYM_B_TYPE(R8) ; set SYM type to binarys30$: RSBI;------------------------------------------------------------------------L; .SBTTL PAGED/READ_ONLY - SYMBOL DISPLAY SPECIAL KERNEL ASTB;++ H; This routine is executed as a special kernel AST in the context of theJ; target process. After performing access checks, this routine determinesK; the size of the process's symbol table. It then, requests non-paged pool,/; into which the symbol table will be copied. L;--ASPECIAL_KERNEL:u4 .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=XDELTA_BREAKPOINTa7 MOVZWL #SS$_NONEXPR,R0 ; assume process non-existantA BBC #PCB$V_DELPEN,PCB$L_STS(R4),10$ ; don't bother if prc dying!y& BRW 50$ ; tell originator nonexpr 10$: BICL3 UICMSK(R5),-N, PCB$L_UIC(R4),R2 ; check if privies are ok+ BEQL 30$ ; privilege is ok. next check.w2 MOVL #SS$_NOWORLD,R0 ; assume world priv needed!4 EXTZV #16,#16,R2,R2 ; was it outside group access?+ BEQL 20$ ; tell originator NOWORLD if soe9 MOVL #SS$_NOGROUP,R0 ; obviously outside member access!n,20$: BRW 50$ ; tell the originator NOGROUP.30$: MOVL #LIB$_NOCLI,R0 ; assume no DCL cli> IFNORD #4,@#CTL$GT_CLINAME,40$ ; is CTL$GT_CLINAME readable?C CMPV #8,#24,@#CTL$GT_CLINAME,#^a/DCL/; is DCL (or variant) mapped?N' BNEQ 50$ ; no... return error NOCLId7 MOVAB @#CTL$AG_CLIDATA,R1 ; base of cli data regionP@ MOVQ PPD$Q_CLISYMTBL(R1),TBLDSC(R5) ; store symbol table descr.' BEQL 50$ ; no... return error NOCLI-< ADDL3 #X_SIZE,TBLDSC(R5),R1 ; add ACB data and table length. JSB G^EXE$ALONONPAGED ; try to allocate it...' BLBC R0,50$ ; No NPP chunk big enuf.  MOVL EF_NUM(R5),EF_NUM(R2) ;\ 9 MOVL STSADR(R5),STSADR(R2) ; \ copy important field frome: MOVL SANITY(R5),SANITY(R2) ; / orginal ACB to the new ACB MOVL BFRADR(R5),BFRADR(R2) ;/, MOVQ R1,NPPDSC(R2) ; save NPP size and adr4 MOVAB TBLCPY(R2),R3 ; calc. SYMBOL TABLE copy adr7 MOVQ TBLDSC(R5),TBLDSC(R2) ; store symbol table descr.5, MOVQ TBLDSC(R5),R0 ; sym tbl desc to R0:R1& ASHL #-9,R0,R0 ; cvt. bytes to pages2 PUSHR #^M ; save reg's trashed by MOVC>40$: MOVC5 #512,(R1),#0,#512,(R3) ; copy one-pagelet at a time* SOBGTR (SP),40$ ; more pagelets to copy?, POPR #^M ; restore trashed reg's* MOVZWL #SS$_NORMAL,R0 ; signify success.& BRB 60$ ; go fixup ACB and queue it;++GL; If we get here, either DCL is not mapped or the large non-paged pool (NPP)K; request was not granted. We use the existing ACB and fill the ACB fields M; with the originating process's IPID and the R0 status to reflect the reasone; for failure.;-- A50$: MOVL ACB$L_ASTPRM(R5),ACB$L_PID(R5) ; move originator's PID w5 MOVL R0,ACB$L_ASTPRM(R5) ; put rtn status in ASTPRM ; MOVB #ACB$M_KAST,ACB$B_RMOD(R5) ; queue as a Special-K ASTs9 MOVAB DISPLAY_ORIGIN,ACB$L_KAST(R5) ; adr of origin code - CLRL ACB$L_AST(R5) ; no normal AST routinet( MOVL #PRI$_TICOM,R2 ; give biggy boost0 JSB G^SCH$QAST ; queue AST to original process RSB;++lK; If we got here, we got the large non-paged pool (NPP) request. A new ACBJJ; is created and filled in with the originating process's IPID and the R0 J; status (which ought be SS$_NORMAL) and the address of the DISPLAY originJ; code. The ACB is then queued to the originating process. The original 2; ACB and data is deallocated via EXE$DEANONPAGED.;--0A60$: MOVL ACB$L_ASTPRM(R5),ACB$L_PID(R2) ; move originator's PID ^A MOVAB DISPLAY_ORIGIN,ACB$L_KAST(R2) ; adr of DISPLAY origin code)= MOVB #ACB$M_KAST!ACB$M_NODELETE,- ; queue as a Special-K ASTy- ACB$B_RMOD(R2) ; we'll handle deleting itt5 MOVL R0,ACB$L_ASTPRM(R2) ; put rtn status in ASTPRMn# PUSHL R5 ; save the original ACB' MOVL R2,R5 ; put new ACB's adr in R5m( MOVL #PRI$_TICOM,R2 ; give biggy boost0 JSB G^SCH$QAST ; queue AST to original process% BLBS R0,70$ ; was the AST queued? s1 MOVQ NPPDSC(R5),R1 ; NPP: R1: size, R2: addresso MOVL R2,R0 ; NPP adr to R0 ' JSB G^EXE$DEANONPGDSIZ ; return to NPP *70$: POPL R0 ; restore the original ACB . JSB G^EXE$DEANONPAGED ; deallocate target ACB RSBM;----------------------------------------------------------------------------B .SBTTL PAGED/READ_ONLY - SYMBOL DISPLAY SPECIAL KERNEL RETURN AST;++rH; This routine is executed as a special kernel AST in the context of theF; originating process. The routine copies the S0VA space copy of theI; target process's symbol table into the originating process's P0VA local-H; buffer and returns the base address of the symbol table in the target H; process. Sets the event flag and returns the status of the operation.;--rDISPLAY_ORIGIN:R1 .IIF DF,ALPHA, .JSB_ENTRY INPUT=,OUTPUT=eXDELTA_BREAKPOINT 3 MOVL @#CTL$GL_PHD,R3 ; get adr of p1 PHD mappingc? CMPL PHD$L_IMGCNT(R3),SANITY(R5) ; compare image cnt w/ sanityA% BNEQ 80$ ; forget it! dismiss ASTT7 BLBC ACB$L_ASTPRM(R5),70$ ; was NPP alloc. sucessful?)2 MOVQ TBLDSC(R5),R0 ; sym.tbl. R0: size, R1: adr1 MOVQ R0,@STSADR(R5) ; move orig. base for bias14 MOVAB TBLCPY(R5),R1 ; SYMTBL_COPY to R1 for MOVC 2 MOVL BFRADR(R5),R3 ; base P0 symbol table s&{C TMESIS.BCKMC"[DECUS.SYMBOL]SYMBOL$AST_LEI.MAR;1P@a>tore' ASHL #-9,R0,R0 ; cvt. bytes to pagesB0 PUSHR #^M ; save reg's trashed by MOVC<60$: MOVC5 #512,(R1),#0,#512,(R3) ; copy one-page at a time( SOBGTR (SP),60$ ; more pages to copy?* POPR #^M ; restore trashed reg'sC70$: MOVL ACB$L_ASTPRM(R5),@STSADR(R5) ; return status of NPP allocs4 MOVL ACB$L_PID(R5),R1 ; originating process's IPID CLRL R2 ; no prio. boost3 MOVL EF_NUM(R5),R3 ; event flag number to be setk! JSB G^SCH$POSTEF ; -- do it --U;80$: BLBS ACB$L_ASTPRM(R5),90$ ; was NPP alloc. sucessful?.% MOVL R5,R0 ; move ACB's adr to R0 8 JSB G^EXE$DEANONPAGED ; return to NPP (ACB and code)  RSB290$: MOVQ NPPDSC(R5),R1 ; NPP: R1: size, R2: adr MOVL R2,R0 ; NPP adr to R0( JSB G^EXE$DEANONPGDSIZ ; return to NPP RSB .END ;SYMBOL$AST_LEI/40$: MOVL #SS$_NORMAL,R0 ; return with NORMAL RSB;++*; Logic for the delete callback functions ;--250$: MOVL (R6),R6 ; walk the list of SYM blocks* CMPL SLHEAD(R5),R6 ; end of the lin"*[DECUS.SYMBOL]SYMBOL$AST_LEI.OPT;1+,N./ 4Hj-C0123KPWO56G ė7ė89GHJ(SYS$LIBRARY:STARLET/INCLUDE:(SYS$DOINIT)<SYS$SYSTEM:SYS.STB/SELECTIVE,SYS$SYSTEM:DCLDEF.STB/SELECTIVEGCOLLECT=NONPAGED_READONLY_PSECTS/ATTRIBUTES=RESIDENT,EXEC$NONPAGED_CODEHCOLLECT=NONPAGED_READWRITE_PSECTS/ATTRIBUTES=RESIDENT,EXEC$NONPAGED_DATA-COLLECT=PAGED_READONLY_PSECTS,EXEC$PAGED_CODE.COLLECT=PAGED_READWRITE_PSECTS,EXEC$PAGED_DATA>COLLECT=INITIALIZATION_PSECTS/ATTRIBUTES=INITIALIZATION_CODE,- EXEC$INIT_CODE,-. EXEC$INIT_000,EXEC$INIT_001,EXEC$INIT_002,-C EXEC$INIT_PFNTBL_000,EXEC$INIT_PFNTBL_001,EXEC$INIT_PFNTBL_002,-> EXEC$INIT_SSTBL_000,EXEC$INIT_SSTBL_001,EXEC$INIT_SSTBL_002 *[DECUS.SYMBOL]SYMBOL.ALPHA_OPT;1+,O./ 41-C0123KPWO567Xė7ܐ&ė89GHJSYS$SHARE:SMI$SHR/SHAREABLESYS$SHARE:SMI$OBJSHR/SHAREABLE1ALPHA$LOADABLE_IMAGES:DCLDEF.STB/SELECTIVE_SEARCH1ALPHA$LOADABLE_IMAGES:SCSDEF.STB/SELECTIVE_SEARCHPSECT_ATTR=$CODE$,PIC,SHR,EXEPSECT_ATTR=CLI$TABLES,SHR,EXE.COLLECT=GBLSECTION,$$CODE_RO,CLI$TABLES,$CODE$*[DECUS.SYMBOL]SYMBOL.CLD;1+,P./ 4M-C0123KPWO56hė7h"ė89GHJ!++ ! Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting ! All rights reserved. ! ------------------------- ! This software is provided "as is" and is supplied for informational purpose ! only. No warranty is expressed or implied and no liability can be accepted ! for any actions or circumstances incurred from the use of this software or ! from the information contained herein. The author makes no claim as to the ! suitablilty or fitness of this software or information contain herein for a ! particular purpose. ! ------------------------- ! This software may be copied and distributed only with the inclusion of this ! copyright notice. !-- ! Modification: ! 14-MAR-1994 Create this file to provide optional SET COMMAND support !-- Ident "SYMBOL V3%4.091" Define Verb SYMBOL Image SYMBOL Cliflags (Foreign) *[DECUS.SYMBOL]SYMBOL.MAR;1+,Q. / 4N -C0123KPWO 56eė79ė89GHJ  .TITLE SYMBOL ; command parser and dispatcher .IDENT "SYMBOL V3%4.091" ; internals demo program... ;-- ; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting ; All rights reserved. ; ------------------------- ; This software is provided "as is" and is supplied for informational purpose ; only. No warranty is expressed or implied and no liability can be accepted ; for any actions or circumstances incurred from the use of this software or ; from the information contained herein. The author makes no claim as to the ; suitablility or fitness of this software or information contain herein for a ; particular purpose. ; ------------------------- ; This software may be copied and distributed only with the inclusion of this ; copyright notice. ;---------------------------------------------------------------------------- ; Modifications: ; 04-JAN-1994: Created this file. ; 20-JAN-1994: added message handling capabilites to prefix error's with ; SYMBOL as the facility name. error condition is returned ; to $STATUS with bit 28 set for conditional statement uses ; in DCL procedures. ; 25-JAN-1994: add hack to fix accvio when CLI$DCL_PARSE chokes on invalid ; expression syntaxes. ; 02-MAR-1994: remove above hack. disallow expressions, only numerics ;-- $CHFDEF ; condition handling facility def's $DSCDEF ; VMS descriptor class/type def's $PRVDEF ; VMS privilege quadword def's $STSDEF ; message code field definitions ;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31 .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0 .IIF DF,ALPHA, .DISABLE FLAGGING ;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONG CMD_LINE: .LONG !,0 PREFIX: .LONG !!6 .ADDRESS SYMSTR VERB: .LONG !!7 .ADDRESS SYMSTR SYMSTR: .ASCII /SYMBOL / ;---------------------------------------------------------------------------- .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY SYMBOL,^M<> MOVAB SYMBOL_MSG_HNDLR,(FP) ; estab. CHF for symbol command PUSHAB CMD_LINE CALLS #1,G^LIB$GET_FOREIGN ; get the command line BLBC R0,10$ PUSHAB VERB ; prepend the foreign command line PUSHAB CMD_LINE ; with the verb before parsing CALLS #2,G^STR$PREFIX BLBC R0,10$ PUSHAB G^LIB$GET_INPUT PUSHAB SYMBOL_CLITABLE ; SYMBOL symbol table PUSHAB CMD_LINE ; the command to be parsed CALLS #3,G^CLI$DCL_PARSE ; parse it. BLBC R0,20$ CALLS #0,G^CLI$DISPATCH ; dispatch to service routine BLBS R0,30$ ;++ ; If an error is returned through CLI$DISPATCH have it formatted the same ; way as a signalled error. The following 'fakes' the format of a signal ; argument array so that the condition handler can be used/called. ; ; Create the following on the stack: ; ; .--------.--------.--------.--------. :AP points to 'x8 TMESIS.BCKQC[DECUS.SYMBOL]SYMBOL.MAR;1N 7 stack by CALLS ; | | #1 |<--- pushed on stack by CALLS ; |--------+--------+--------+--------| :SP ; | address of the faked SIGNAL array |----. ; |--------+--------+--------+--------| | ; | | #1 | <--' ; |--------+--------+--------+--------| ; | returned status from CLI$DISPATCH | ; `-----------------------------------' ;-- ASSUME CHF$L_SIGARGLST EQ 4 ; assumption for fake sig array 10$: PUSHL R0 ; fake a signal arg array PUSHL #1 ; so that the condition handler PUSHAB (SP) ; can be CALL(S)ed CALLS #1,SYMBOL_MSG_HNDLR ; call CHF to report error 20$: BBSS #STS$V_INHIB_MSG,R0,30$ ; set the 'no-signal' bit 30$: RET ; bye-bye ;++ ; Condition handler. Changes facility string to SYMBOL in error messages. ; Assume that the AP point to an array which points to the signal array. ; ; ; .--------.--------.--------.--------. ; | | 1 or 2 | :AP ; |--------+--------+--------+--------| ; | address of SIGNAL array |----. ; |--------+--------+--------+--------| | ; | adr of MECHANISM array (not used) | | ; |--------+--------+--------+--------| | ; ~ ~ | ; ~ ~ | ; |--------+--------+--------+--------| | ; | | # args |<---' ; |--------+--------+--------+--------| ; | condition code | ; |--------+--------+--------+--------| ; ~ optional condition code ~ ; ~ related arguments ~ ; |--------+--------+--------+--------| ; | program counter | ; |--------+--------+--------+--------| ; | processor status longword | ; `-----------------------------------' ; ;-- .ENTRY SYMBOL_MSG_HNDLR,0 MOVL CHF$L_SIGARGLST(AP),R11 ; get adr of signal arg array CMPZV #STS$V_FAC_NO,- ; is this an error from CLI? #STS$S_FAC_NO,- CHF$L_SIG_NAME(R11),- #CLI$_FACILITY BNEQ 10$ ; NO? branch to 10$ MOVL #1,CHF$L_SIG_ARGS(R11) ; limit CLI errors to 1 args 10$: $PUTMSG_S MSGVEC=(R11),- ; output the message FACNAM=PREFIX ; prefixed with SYMBOL BLBC CHF$L_SIG_NAME(R11),20$ ; exit if an error? MOVL #SS$_CONTINUE,R0 ; informational... continue RET 20$: BBSS #STS$V_INHIB_MSG,- ; set the 'no-signal' bit CHF$L_SIG_NAME(R11),30$ 30$: $EXIT_S CHF$L_SIG_NAME(R11) ; exit .END SYMBOL i*[DECUS.SYMBOL]SYMBOL.OPT;1+,R./ 4.$-C0123KPWO56N#ė78ė89GHJSYS$SHARE:SMI$SHR/SHAREABLESYS$SHARE:SMI$OBJSHR/SHAREABLE#SYS$SYSTEM:SYS.STB/SELECTIVE_SEARCH&SYS$SYSTEM:DCLDEF.STB/SELECTIVE_SEARCH&SYS$SYSTEM:SCSDEF.STB/SELECTIVE_SEARCHPSECT_ATTR=$CODE$,PIC,SHR,EXEPSECT_ATTR=CLI$TABLES,SHR,EXE.COLLECT=GBLSECTION,$$CODE_RO,CLI$TABLES,$CODE$*[DECUS.SYMBOL]SYMBOL.RNH;1+,S. / 4Q o-C0123KPWO564"ė7'ė89GHJ.nfl accept .nfl bold .fl space .lm 0 .rm 78 !Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting .rm 72 .br .b 1 SYMBOL .lm 1 .br SYMBOL provides the capability to define, display and delete DCL symbols in the context of any process in a VAXcluster. SYMBOL can be used by any user in the VMScluster to define, display, or delete symbols in their own symbol table or in the symbol table of any process in the VMScluster. Privileges are require to affect any process which the user does not own or have rights to access. .b SYMBOL displays the symbol table's contents using the same output format as the OpenVMS DCL command '$ SHOW SYMBOL'. A single equal sign '=' is used to denote LOCAL symbols and, the double equal sign '==' is used for denoting GLOBAL symbols. Binary symbols are formatted with the familiar decimal, hexadecimal and octal presentation. .b Format .b .lm 3 SYMBOL#/qualifiers##parameters .lm 0 .rm 70 .br 2 Parameters .lm 1 .br The SYMBOL command performs entirely different functions based upon the qualifiers used with the verb. The command may require none, one, or two parameters to be specified, depending on the /QUALIFIER(S) specified with the command verb. .lm 0 .rm 68 .br 3 symbol-name .lm 1 .br Specifies a string of 1 to 255 characters for the symbol name. The name can contain any alphanumeric characters from the DEC Multinational Character Set, the underscore (_), and the dollar sign ($). However, the name must begin only with an alphabetic character (uppercase and lowercase characters are equivalent), an underscore, or a dollar sign. .b The symbol-name parameter must be specified when creating and removing symbols in the context of the target process. .lm 0 .rm 68 .br 3 equivalence-string .lm 1 .br This parameter can consist of any character string, a numerical constant, a lexical function, or a combination of these entities. The components of the expression are assigned to the symbol. Any literal character strings inside the expression must be enclosed in double-quotation marks ("" ""). .b The result of expression evaluation will be a character string. .b DCL uses a buffer that is 1024 bytes long to hold an assignment statement and to evaluate the expression. The length of the symbol name, the expression, and the expression's calculations cannot exceed 1024 bytes. .b The equivalence-name parameter must be specified when creating a symbol in the context of the target process. It is not used when removing or displaying symbol definitions. .lm 0 .rm 68 .br 3 numerical-value .lm 1 .br This parameter can consist of any numerical constant. The integer value is assigned to the symbol. The value, by default, is expressed in decimal. Hexadecimal values must be prefixed with %X. Octal values must be prefixed with %O. .b The numerical-value name parameter must be specified when creating a binary symbol in the context of the target process. It is not used when removing or displaying symbol definitions. .lm 0 .rm 68 .br 3 match-pattern .lm 1 .br Specifies a string of 1 to 255 characters which will be used as display criteria when displaying the contents of a symbol table. The pattern can contain any alphanumeric characters from the DEC Multinational Character Set, the underscore (_), the dollar sign ($) and any standard VMS wildcard characters (* and %). Symbols which are displayed will match the pattern specified. .b The optional match-pattern parameter can be specified when displaying the symbols of the target process. If a match pattern is omitted, all the symbols are displayed. .lm 0 .rm 70 .br 2 Qualifiers .lm 1 .br The SYMBOL command performs entirely different functions based on the qualifiers used with the verb. The command must specify the process Id using the /IDENTIFICATION qualifier. All of the other qualifiers are either optional or, are used to select the specific function of the SYMBOL command. .lm 0 .rm 68 .br 3 /BINARY .lm 1 .br /BINARY .b Specifies that you are using the SYMBOL command to create an integer symbol definition in the context of (7ʇ TMESIS.BCKSC[DECUS.SYMBOL]SYMBOL.RNH;1Q V the target process. This qualifiers can only be used with and must be specified after the /SET qualifier. .b The default action of the SYMBOL command is to create a string symbol. .lm 0 .rm 68 .br 3 /DELETE .lm 1 .br /DELETE .b Specifies that you are using the SYMBOL command to remove a symbol definition in the context of the target process specified with the required /IDENTIFICATION qualifier. .b This qualifier is a positional qualifier. It must appear in the command before other qualifiers such as: /IDENTIFICATION and /LOCAL. .lm 0 .rm 68 .br 3 /GLOBAL .lm 1 .br /GLOBAL .b Specifies that you are using the SYMBOL command to create or remove a global symbol definition in the context of the target process or, to display the global symbols of the target process. If a symbol is a global symbol then, you may omit this qualifier. .b This is the default action of the SYMBOL command. .lm 0 .rm 68 .br 3 /IDENTIFICATION .lm 1 .br /IDENTIFICATION=pid .b Specifies the system-assigned process identification (PID) code. When a process is created a unique PID is assigned to the process. Use the PID of the target in question to specify the process. .b This qualifier is an optional qualifier. If it is omitted ot the PID is specified as zero (0), the current process id is used. You can omit any leading zeros in specifying the PID code. .lm 0 .rm 68 .br 3 /LOCAL .lm 1 .br /LOCAL .b Specifies that you are using the SYMBOL command to create or remove a local symbol definition in the context of the target process or, to display the local symbols of the target process. If a symbol is a local symbol then, you must specify this qualifier. .lm 0 .rm 68 .br 3 /SET .lm 1 .br /SET .b Specifies that you are using the SYMBOL command to create a symbol definition in the context of the target process specified with the required /IDENTIFICATION qualifier. .b This qualifier is a positional qualifier. It must appear in the command before other qualifiers such as: /IDENTIFICATION, /LOCAL and /BINARY. .lm 0 .rm 68 .br 3 /SHOW .lm 1 .br /SHOW .b Specifies that you are using the SYMBOL command to display symbol definitions of the target process specified with the required /IDENTIFICATION qualifier. This is the default action of the SYMBOL command and may be omitted from the command line. .b This qualifier is a positional qualifier. It must appear in the command before other qualifiers such as: /IDENTIFICATION and /LOCAL. .lm 0 .rm 70 .br 2 Examples .lm 1 .b .lm 1 1. $ SYMBOL/SHOW/ID=4F *MOD* .b The SYMBOL command in this example will display the symbols in the process specified by the ID=4F which match the match pattern of *MOD*. .b 3 2. $ SYMBOL/SET/IDENT=309 LO*GOUT LOGOUT/FULL .b The SYMBOL command in this example is defining the abbreviated global symbol LO*GOUT to be LOGOUT/FULL for the process with pid=309. .b 3 3. $ SYMBOL/DELETE/GLOBAL/ID=40401A94 GREP .b The SYMBOL command in this example deletes the global symbol GREP which should never have been defined in the context of the remote VMS process with the pid=40401A94. .b 3 4. $ SYMBOL/SET/LOCAL/ID=4F TIME WRITE SYS$OUTPUT "''F$TIME()'" .b The SYMBOL command in this example is defining the local symbol TIME to be WRITE SYS$OUTPUT "''F$TIME()'" for the process with pid=4F. The SYMBOL command associates all text from the end of the symbol-name parameter string through the end of the command line with the equivalence-name parameter string. Therefore, there is no need to enclose the string in quotation marks ("#"). If quotation marks are used, they will be assigned to the symbol along with the rest of the equivalence-name string. .b 3 5. $ SYMBOL/SET/BINARY DOSIQ 0 .b The SYMBOL command in this example is defining integer symbol DOSIQ to be 0. In this case, the /IDENTIFICATION qualifier was omitted; therefore, the symbol will be defined in the current process. .lm 0 .rm 70 .br 2 Return_Errors .lm 1 .br The following lists common system errors which may be returned when using the SYMBOL command. The cause for the error and any possible recovery procedures and/or corrective actions are described in each error message sub-topic. .lm 0 .rm 68 .br 3 ABSYMD .lm 1 .br .nofill %DCL-W-ABSYMD,#abbreviated#symbol#definition#conflict#- ###############rename symbol .fill .b The SYMBOL/SET command specified a symbol name which is not unique and is in conflict with an existing abbreviated symbol definition. .b Change the name of the symbol and/or check the symbol spelling. .lm 0 .rm 68 .br 3 BADACTRL .lm 1 .br %SYMBOL-E-BADACTRL,#remote#access#control#info#invalid .b The SYMBOL command specified the process id of a process on a remote node in the cluster and the issue of the command is not authorized on the target node. .b Check that specified PID represents an active process on an authorized node. .lm 0 .rm 68 .br 3 BADPARAM .lm 1 .br %SYMBOL-F-BADPARAM,#bad#parameter#value .b The symbol name specified with the SYMBOL command does not conform with the accepted format for formulating symbol names. The symbol name may contain one or more of the following unacceptable ASCII characters. .b .literal (null) ! " # ( ) + , - . / ; < > ? @ [ ] ^ .end literal .b Correct the symbol to conform with the conventions. .lm 0 .rm 68 .br 3 EXPSYN .lm 1 .br .nofill %SYMBOL-W-EXPSYN,#invalid#expression#syntax#- ##################check#operators#and#operands .fill .b The SYMBOL/SET/BINARY command specified an expression syntax which can not be evaluated or the expression contained an undefined local symbol. .b Use a valid numeric expression, correct the spelling of any symbols used in the expression statement or define any undefined symbols used in the expression with a numeric value in the local process. .lm 0 .rm 68 .br 3 INPCONERR .lm 1 .br %SYMBOL-F-INPCONERR,#input#conversion#error .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier is not a valid hexadecimal value. .b Check that valid hexadecimal digits have been specified for the PID. .lm 0 .rm 68 .br 3 INSFMEM .lm 1 .br %SYMBOL-F-INSFMEM,#insufficient#dynamic#memory .b There is insufficient free nonpaged memory available to complete the operation. The most probable cause for this error is insufficient contiguous nonpaged memory available to hold the target process's symbol table. The command SHOW MEMORY/POOL/FULL can be used to verify this condition. .b If there is insufficient contiguous nonpaged memory, increase the sysgen parameters NPAGEDYN and NPAGEVIR to accomodate, at a minimum, the maximum size of a process's symbol table which is 256000 (512*500) bytes. .lm 0 .rm 68 .br 3 IVCHAR .lm 1 .br .nofill %SYMBOL-W-IVCHAR,#invalid#numeric#value#- ##################check#for#invalid#digits .fill .b The SYMBOL/SET/BINARY command specified an illegal character in the numeric value. .b Check that valid digits have been specified for the radix operand specifier being used. .lm 0 .rm 68 .br 3 IVQUAL .lm 1 .br .nofill %SYMBOL-W-IVQUAL,#unrecognized#qualifier#- ##################check#validity,#spelling,#and#placement .fill .b An illegal qualifier was specified with the SYMBOL command or the spelling of the qualifier is incorrect. .b Check the usage and correct the spelling of any qualifiers used. .lm 0 .rm 68 .br 3 IVSYMB .lm 1 .br .nofill %SYMBOL-W-IVSYMB,#invalid#symbol#name#- ##################start#name#with#an#alphabetic#character .fill .b The symbol name specified with the SYMBOL command does not comform with the accepted format for formulating symbol names. Symbols must start with an alphabetic character, an underscore (_), or the dollar ($). .b C)6 TMESIS.BCKSC[DECUS.SYMBOL]SYMBOL.RNH;1Q Borrect the symbol to conform with the conventions. .lm 0 .rm 68 .br 3 NOCLI .lm 1 .br %SYMBOL-F-NOCLI,#no#CLI#present#to#perform#function .b The target process does not have the DCL CLI mapped or it is an image running in a detached process which has no symbol table. .lm 0 .rm 68 .br 3 NOGROUP .lm 1 .br %SYMBOL-F-NOGROUP,#operation#requires#GROUP#privilege .b The current process attempted to use SYMBOL and specified the PID of a process in the same group without having the GROUP privilege. .lm 0 .rm 68 .br 3 NONEXPR .lm 1 .br %SYMBOL-W-NONEXPR,#nonexistent#process .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier does not represent a valid active process on the system. .b Check that specified PID represents an active process. .lm 0 .rm 68 .br 3 NONXPAG .lm 1 .br %SYSTEM-E-NONXPAG,#non-existent#page .b The SYMBOL command was issued but the supporting loadable executive image, SYS$LOADABLE_IMAGES:SYMBOL$AST_LEI.EXE, has not been loaded. .b Load SYS$LOADABLE_IMAGES:SYMBOL$AST_LEI.EXE using SYMLOADER.EXE. .lm 0 .rm 68 .br 3 NOSERVER .lm 1 .br %SYMBOL-E-NOSERVER,#SMI#Server#not#running#in#target#node .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier specified a process on a remote member of the VAXcluster which is not currently running the SMISERVER process. .b Check that the SMISERVER is running and, if necessary, restart it. .lm 0 .rm 68 .br 3 NOSUCHNODE .lm 1 .br %SYMBOL-F-NOSUCHNODE,#remote#node#is#unknown .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier does not represent a process on a valid active member of the VAXcluster. .b Check that specified PID represents an active process. .lm 0 .rm 68 .br .!3 NOTIMP .!.!.lm 1 .!.br .!%SYMBOL-F-NOTIMP,#not#implemented .!.b .!The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier .!does not represent a valid active process on an OpenVMS VAX system. .!SYMBOL currently supports only VAX systems in the cluster. Support for OpenVMS .!AXP systems is forthcoming. .!.b .!Check that specified PID represents an active process a VAX system. .!.lm 0 .!.rm 68 .!.br 3 NOTMPMBX .lm 1 .br %SYMBOL-F-NOTMPMBX,#operation#requires#TMPMBX#privilege .b The current process attempted to use SYMBOL and specified the PID of a process on a remote node without having the TMPMBX privilege. .lm 0 .rm 68 .br 3 NOWORLD .lm 1 .br %SYMBOL-F-NOWORLD,#operation#requires#WORLD#privilege .b The current process attempted to use SYMBOL and specified the PID of a process outside its group without having the WORLD privilege. .lm 0 .rm 68 .br 3 SUSPENDED .lm 1 .br %SYMBOL-F-SUSPENDED,#process#is#suspended .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier specified a process which is suspended. .lm 0 .rm 68 .br 3 TIMEOUT .lm 1 .br %SYMBOL-E-TIMEOUT,#remote#operation#has#timed#out .b The process id (PID) specified with the SYMBOL/IDENTIFICATION qualifier specified a process on a remote member of the VAXcluster and the request to that remote node timed out. .lm 0 .rm 68 .br 3 UNDSYM .lm 1 .br .nofill %DCL-W-UNDSYM,#undefined#symbol#-#check#validity#and#spelling .fill .b The SYMBOL/DELETE command specified a symbol name which does not exists. .b Change the name of the symbol and/or check the symbol spelling. .lm 0 .rm 70 .br 2 Version .lm 1 .br SYMBOL#version#v3%4.091 .br Copyright##1993,#1994#by#Brian#Schenkenberger#and#TMESIS#Consulting e$*[DECUS.SYMBOL]SYMBOLPERM.ALPHA_OPT;1+,T./ 4 "-C0123KPWO56+ė7+ė89GHJ ALPHA$LOADABLE_IMAGES:DCLDEF.STB*[DECUS.SYMBOL]SYMBOLPERM.MAR;1+,U. / 4N Z-C0123KPWO 56[-ė7[N.ė89GHJ - .TITLE PERMSYM ; define a symbol permanent5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++L; This program establishes a permanent symbol definition for SYMBOL which isJ; activated by the foreign command symbol definition: SYMBOL=="$SYMBOL". ;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS ConsultingM; All rights reserved. 3; -------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.3; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:H; 09-FEB-1994: created this file. creates SYMBOL as a permanent symbol.;--; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly .LINK "SYS$SYSTEM:SYS.STB"/SE! .LINK "SYS$SYSTEM:DCLDEF.STB"/SE( $LIBCLIDEF ; LIB${GET/SET}_SYMBOL codes% $CLIMSGDEF ; CLI error message codesM;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONGEAUTODIN:.LONG ^x00000000,^x1DB71064 ; Autodin-II CRC polynomial table> .LONG ^x3B6E20C8,^x26D930AC ; -------------------------------? .LONG ^x76DC4190,^x6B6B51F4 ; used to calculate a hash value? .LONG ^x4DB26158,^x5005713C ; of the symbol to determine the@ .LONG ^xEDB88320,^xF00F9344 ; index of the symbol table list-? .LONG ^xD6D6A3E8,^xCB61B38C ; head where the symbol's (SYM) = .LONG ^x9B64C2B0,^x86D3D2D4 ; block will/should be queued.> .LONG ^xA00AE278,^xBDBDF21C ; -------------------------------ARGLST: .LONG 1 .ADDRESS SYMBOLSYMBOL: .ASCID /SYMBOL/$SYMBOL: .ASCID /$SYMBOL/M;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY PERM_SYM,^m<> PUSHAL #LIB$K_CLI_GLOBAL_SYM PUSHAB $SYMBOL PUSHAB SYMBOL CALLS #3,g^LIB$SET_SYMBOL BLBS R0,10$ RET<10$: $CMEXEC_S ROUTIN=SET_PERM,- ;call SET_PERM at exec mode ARGLST=ARGLST RET;++L; This routine calculates and locates the listhead in which the symbol's SYML; block should be located. It then walks-the-list looking for the specified=; symbol. When it is located, it sets the type to PERManent.;--' .ENTRY SET_PERM,^m ' MOVQ @4(AP),R4 ; get the symbol name0 CRC AUTODIN,#-1,R4,(R5) ; calc the hash value - BICL2 #^C^XFF,R0 ; calc the listhea*A TMESIS.BCKUC[DECUS.SYMBOL]SYMBOLPERM.MAR;1N d index7 MOVAB @#CTL$AG_CLIDATA,R1 ; base of cli data region= MOVAQ @PPD$Q_CLISYMTBL+4(R1)[R0],R6 ; get the assoc listhead+ MOVL R6,R7 ; save for end-of-line check210$: MOVL (R6),R6 ; walk the list of SYM blocks# CMPL R7,R6 ; end of the line??? BEQL 20$ ; quit if at end.5 MOVAB SYM_T_SYMBOL(R6),R1 ; get ascic symbol adress' MOVZBL (R1)+,R0 ; extract the length0 CMPC5 R0,(R1),#0,R4,(R5) ; is this our symbol?& BNEQ 10$ ; better luck next round.2 TSTW SYM_W_NONUNIQUE(R6) ; is the symbol unique?& BLSS 10$ ; branch if not unique... 4 TSTW SYM_W_PROCLEVEL(R6) ; is it a gbl/lcl symbol? BGEQ 10$ ; local symbol test4 MOVB #SYM_K_PERM,SYM_B_TYPE(R6) ; make it permanent( MOVL #CLI$_NORMAL,R0 ; signal success RET020$: MOVL #CLI$_UNDSYM,R0 ; return with UNDSYM RET .END PERM_SYM*[DECUS.SYMBOL]SYMCLITBL.CLD;1+,V./ 4M*-C0123KPWO56 0ė7C1ė89GHJ !++ ! Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting ! All rights reserved. ! ------------------------- ! This software is provided "as is" and is supplied for informational purpose ! only. No warranty is expressed or implied and no liability can be accepted ! for any actions or circumstances incurred from the use of this software or ! from the information contained herein. The author makes no claim as to the ! suitablilty or fitness of this software or information contain herein for a ! particular purpose. ! ------------------------- ! This software may be copied and distributed only with the inclusion of this ! copyright notice. !-- ! Modification: ! 20-DEC-1993 Added syntax for SYMBOL/SHOW ! 30-DEC-1993 Change default syntax SYMBOL/SHOW ! 04-JAN-1994 Allow foreign symbol syntax and internal parsing ! 25-JAN-1994 Add /BINARY qualifier and BINSET syntax !-- Module SYMBOL_CLITABLE Ident "SYMBOL V3%4.091" Define Syntax DELSYM Routine SYMDELSET Qualifier DELETE,Default Qualifier SET,Nonnegatable Disallow SET Qualifier GLOBAL Qualifier LOCAL Disallow GLOBAL and LOCAL Qualifier IDENT,Nonnegatable,Value(Required) Parameter P1,Label=Symbol,Prompt="Symbol", Value(Type=$INSYM,Required) Define Syntax SETSYM Routine SYMDELSET Qualifier SET,Default Qualifier DELETE,Nonnegatable Disallow DELETE Qualifier GLOBAL Qualifier LOCAL Disallow GLOBAL and LOCAL Qualifier IDENT,Nonnegatable,Value(Required) Qualifier BINARY,Nonnegatable,Syntax=BINSET Parameter P1,Label=Symbol,Prompt="Symbol", Value(Type=$INSYM,Required) Parameter P2,Label=Value,Prompt="String", Value(Type=$REST_OF_LINE,Required) Define Syntax BINSET Parameter P1,Label=Symbol,Prompt="Symbol", Value(Type=$INSYM,Required) Parameter P2,Label=Value,Prompt="Value", Value(Type=$Number,Required) Define Verb SYMBOL Routine SYMDISPLAY Qualifier GLOBAL Qualifier LOCAL Disallow GLOBAL and LOCAL Qualifier IDENT,Nonnegatable,Value(Required) Qualifier SET,Nonnegatable,Syntax=SETSYM Qualifier DELETE,Nonnegatable,Syntax=DELSYM Qualifier SHOW,Nonnegatable,Default Disallow SET and DELETE and SHOW Parameter P1,Label=Match,Prompt="Match Pattern", Value(Type=$Quoted_String,Default="*") *[DECUS.SYMBOL]SYMCLUSTER.MAR;1+,W./ 4O-C0123KPWO56*5ė7b-9ė89GHJ/ .TITLE SYMCLUSTER ; VAXcluster SYMBOL support5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++K; This program demonstrates the use of the undocumented SMI shareable imageL; library functions which provide the interface to the VAXcluster SMISERVER.;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting8; All rights reserved. ; ------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:#; 06-FEB-1994: created this file...J; Version V3: -----------------------------------------------------------J; 24-FEB-1994: V3 (Include OpenVMS/AlphaAXP Support) Removed architecture; type check.;--; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here when assembling+ $DSCDEF ; VMS descriptor type/class def's) $PCBDEF ; Processor control block def's. $PRVDEF ; Processor privilege quadword def's+ $SSDEF ; system service error definitionsO;------------------------------------------------------------------------------9SMI$K_FUNC_SHOW = 1 ; symbolic name of SMI function codes=SMI$K_FUNC_SHOW_NEXT = 2 ; obtained from the source code. no<SMI$K_FUNC_MODIFY = 5 ; known include library modules exist.M;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONGSMICTX: .LONG 0CURPRV: .QUAD 0NOPRIV: .LONG -1,-14 ; S * mSec * uSec *TC ; TC - tick cnt = 100 nSecs;TIMEOUT: .LONG -10 * 1000 * 1000 *10,-1; 10 second timeout.NODENAME_DSC: .LONG 16 .ADDRESS NODENAME_STRNODENAME_STR: .BLKB 16BUFF_LEN = 256?BUFF_DESC: .LONG !!BUFF_LEN .ADDRESS BUFFERBUFFER: .BLKB BUFF_LEN6COMMAND: .LONG !,0GETLINE: .ASCID /$LINE/MCR: .ASCID /MCR SYMBOL /O;------------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .IF DF ALPHA7 .CALL_ENTRY LABEL=SYMCLUSTER,HOME_ARGS=TRUE,MAX_ARGS=1 .IF_FALSE .ENTRY SYMCLUSTER,0 .ENDC PUSHAB COMMAND PUSHAB GETLINE0 CALLS #2,G^CLI$GET_VALUE ; get the command line BLBS R0,10$ RET,10$: PUSHAB MCR ; prepend the command line% PUSHAL #6 ; with MCR before using PUSHAL #1 PUSHAB COMMAND PUSHAB COMMAND CALLS #5,G^STR$REPLACE BLBS R0,20$ RET820$: $CMKRNL_S ROUTIN=GET_NODE_FROM_PID,- ; get nodename ARGLST=(AP) BLBS R0,30$ RET 330$: PUSHAB SMICTX ; initialize SMI context block CALLS #1,G^SMI$INIT BLBS R0,40$ RET/40$: PUSHAB TIMEOUT ; setup a commun. timeout$ PUSHAB SMICTX ; SMI context block CALLS #2,G^SMI$SET_TIMEOUT ; BLBS R0,50$ RET:50$: PUSHAB NODENAME_DSC ; add the remote nodename to the$ PUSHAB SMICTX ; SMI context block CALLS #2,G^SMI$SET_NODENAME BLBS R0,60$ RET;60$: $SE+ˠw TMESIS.BCKWC[DECUS.SYMBOL]SYMCLUSTER.MAR;1OTPRV_S PRVPRV=CURPRV ; get and save current privies BLBS R0,70$ RET 70$: ASSUME PRV$V_GROUP LT 32 ; 6 ASSUME PRV$V_WORLD LT 32 ; \ assuptions for the next 6 ASSUME PRV$V_SETPRV LT 32 ; / two BICL2 instructions ASSUME PRV$V_TMPMBX LT 32 ; + CLRL CURPRV+4 ; no 2nd longword privies & BICL2 #^C<- ; if local process has % PRV$M_GROUP!- ; group privilege,% PRV$M_WORLD!- ; world privilege,) PRV$M_TMPMBX!- ; tmpmbx privilege or' PRV$M_CMKRNL>,- ; cmkrnl privilege' CURPRV ; remote should inherit same8 BICL2 #PRV$M_SETPRV,CURPRV ; don't inherit auth.privies PUSHL #0 ; prmflg = 0) PUSHAB NOPRIV ; prv vector (all privs)" PUSHL #0 ; enbflg = 0 (disable)0 PUSHL #SMI$K_FUNC_MODIFY ; remote command value$ PUSHAB SMICTX ; SMI context block+ CALLS #5,G^SMI$PRIV ; disable all privies BLBS R0,80$ RET80$: PUSHL #0 ; prmflg = 0, PUSHAB CURPRV ; current active prv vector! PUSHL #1 ; enbflg = 1 (enable)0 PUSHL #SMI$K_FUNC_MODIFY ; remote command value$ PUSHAB SMICTX ; SMI context block. CALLS #5,G^SMI$PRIV ; enable current privies BLBS R0,90$ RET/90$: PUSHAB BUFF_DESC ; adr of word for length* PUSHAB BUFF_DESC ; adr of buffer (ascid)* PUSHAB COMMAND ; adr of command (ascid). PUSHL #SMI$K_FUNC_SHOW ; remote command value$ PUSHAB SMICTX ; SMI context block5 CALLS #5,G^SMI$RCOMM ; issue command and get output BLBS R0,110$ CMPL R0,#SS$_NOPRIV BNEQ 100$ MOVL #SS$_NOTMPMBX,R0 100$: RET4110$: PUSHAB BUFF_DESC ; buffer filled by SMI$RCOMM) CALLS #1,G^LIB$PUT_OUTPUT ; write it out BLBS R0,120$ RET9120$: MOVW #BUFF_LEN,BUFF_DESC ; reset buffer desc length+ PUSHAB BUFF_DESC ; adr of word for length* PUSHAB BUFF_DESC ; adr of buffer (ascid)$ PUSHL #0 ; adr of command (ascid)3 PUSHL #SMI$K_FUNC_SHOW_NEXT ; remote command value$ PUSHAB SMICTX ; SMI context block6 CALLS #5,G^SMI$RCOMM ; get subsequent command output BLBS R0,130$ RET:130$: CMPL R0,#SS$_NORMAL ; returns SS$_NORMAL when there BEQL 110$ ; is more output  RET;++K; This routine will obtain the nodename of the node which corresponds with I; the specified EPID (/IDENT qualifier argument) by extracting the node'sJ; index value from the EPID and searching the local node cluster database.J; This routine is used because the $GETSYI CSIDADR argument expects a trueI; CSID. After the 4th incarnation of a node in the cluster, the CSID canI; no longer be constructed from the node seq # and the node index numbersH; in the given EPID. This routine uses the node index number taken fromG; the EPID(21:28) to index in the the CSV (Cluster System block Vector)I; which is pointed to by CLU$GL_CLUSVEC. If the index is value id valid,I; the vector will contain the address of the Cluster Status Block (a SOVAI; address). If the value is invalid, the slot contains the next sequence(; id (a positive non=-negative value). ;H; RTFM: 'VAXcluster Principles', Roy G. Davis, Digital Press EY-M740E-DP1; Chapter 7: 'The VAXcluster Connection Manager',1; Section 9: 'Connection Manager Data Structures';--# .PSECT $$CODE_DATA_RW,WRT,EXE,LONG- .ENTRY GET_NODE_FROM_PID,^M: PUSHAB NODENAME_STR+16 ; push adr of descriptor data end8 PUSHAB NODENAME_DSC ; push adr of descriptor beginning( MOVAB (SP),R0 ; save adr of INADR arg8 $LKWSET_S INADR=(R0) ; lock in WS/no paging at IPL$_SCS# BLBS R0,10$ ; locked down tight? RET ; no... tell user.710$: MOVL #SS$_NOSUCHNODE,R10 ; assume error NOSUCHNODE MOVL 4(AP),R2 ; get the EPID BGTR 20$ ; a valid EPID?* BRW 60$ ; zero or neg? not a valid EPID20$: .IF DF ALPHA 3 $LOCK_PAGE ERROR=60$ ; use $LOCK_PAGE macro on AXP .IF_FALSE' PUSHAB 50$ ; push adr of routine end) PUSHAB 30$ ; push adr of routine start( MOVAB (SP),R0 ; save adr of INADR arg5 $LKWSET_S INADR=(R0) ; lock WS/no paging @IPL$_SCHED# BLBS R0,30$ ; locked down tight? RET ; no... tell user. .ENDC@30$: EXTZV #PCB$V_EPID_NODE_IDX,- ; extract node index from EPID #PCB$S_EPID_NODE_IDX,- R2,R1+ BEQL 50$ ; is it zero? not a valid index9 CMPW R1,CLU$GW_MAXINDEX ; is it bigger than the maximum?! BGEQU 50$ ; not a valid index* LOCK LOCKNAME=SCS ; acquire SCS spinlock 3 MOVL @#CLU$GL_CLUSVEC,R0 ; get the base of the CSV4 MOVL (R0)[R1],R0 ; get adr of Cluster System Block) BGEQ 40$ ; not a valid CSB index entry= EXTZV #PCB$V_EPID_NODE_SEQ,- ; extract node seq. # from EPID! #PCB$S_EPID_NODE_SEQ,R2,-(SP) * INSV (SP)+,#16,- ; move to hi word in R1 #PCB$S_EPID_NODE_SEQ,R1 % CMPZV #0,#<16+PCB$S_EPID_NODE_SEQ>,-3 CSB$L_CSID(R0),R1 ; does it compare against CSID?% BNEQ 40$ ; nope... not valid index4 MOVL CSB$L_SB(R0),R1 ; get adr of the system block9 MOVAL SB$T_NODENAME(R1),R1 ; and the adr of the nodename4 MOVQ NODENAME_DSC,R2 ; move nodename desc to R2:R3- MOVZBL (R1),NODENAME_DSC ; modify the length* MOVZBL (R1)+,R0 ; make ascic into a desc1 MOVC5 R0,(R1),#20,R2,(R3) ; copy nodename string) MOVZWL #SS$_NORMAL,R10 ; return success440$: UNLOCK LOCKNAME=SCS ; release the SCS spinlock@50$: .IIF DF,ALPHA, $UNLOCK_PAGE ; use $UNLOCK_PAGE macro on AXP60$: MOVL R10,R0 RET .END*[DECUS.SYMBOL]SYMDELSETB.MAR;1+,X.$/ 4P$-C0123KPWO 56+b:ė7d<ė89GHJ5 .TITLE SYMDELSETB ; set a symbol in another process5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++I; This program demonstrates the use of a piggyback special kernel AST andH; provides a mechanism to set or delete DCL symbols in another process. ;I; This program uses the CLI$func interface RTLs to obtain the pertainent H; information from the command line. A command definition file providesH; a DCL like command interface and syntax. When the command informationH; has been obtained, a kernel mode routine is executed which will alloc-H; ate non-paged pool for an ACB and an extension which contains pertain-H; ent information from the command line. This ACB is then queued to theG; target process. The AST routines are located in a Loadable Executive; Image (LEI).;--H; USES: A great utility for teaching a lesson to un*x types on OpenVMS E; systems that insist on creating throngs of symbols to emulate their8; beloved cryptic un*x command interfaces. For example:; M; SYMBOL/SET/ID=# GREP WRITE SYS$OUTPUT "Grep, schmep! Go YACC yourself off!";--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS ConsultingM; All rights reserved. 3; -------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of , h8 d}EI.MAR;1T5 ;I/10G`R#\LXA*s+:LWw[W~2Ut}q~%erORb+iKe> Z4+\O>#23XuvSu< Tpp]SCvD==Y10zae2;bOvrbmgK=G%m1z, CGCC>3 NQY`b m9bG0z]1&7oUCZLI\bC}&F+(O@5Pu=V9W6@`yc1[~N) 'Fw4@4< {'Y% +Ka1<*M=9H6@"/eKM T@`y-o ?"}<_  Aao3RVS9l& TNz=-BM/tA=IXaS9$!%.YJ6DK-sb$Wg73V[$ak4L%#s~sp?12@R__{vE`PoPq u.W]c@y'UA ]@+ Vfc.O*h1NWW?& -rtT[f'y:|6 t>7$rb)q:$:8//G<0tP#nd:] 9rj~'H+@ Z)*2D;B7Z \Uw'fK VrO(RI9^PIEE|6edb\7)f%"TO WNJAFmN^VD|SF?`wh; ?x+jXM#H8Fq*RZ}yW  "B9AX ERy " l#Me6%wC5fAb o9W#vRD BP&! sFF4<PFQ0 xcWw=T:*_G:IVag4XFVZ ?,K~-[# 4Lks Us7G\#D7g1T(D[s c 7-DnYvdp*?K2'Ij W}{+xYI,Kh\R6I Z0 u1]%}TK@Zx1l@3aO:} ONI5cyBO3`;(*)D.eP'e/ emM>aI8n94`y-Kfiv?nAC<@2{ g%U1?#fS9g0u:+d_><8E"@ 0 3lq}40P(3s /$  e!y#z Tud'~kC:A7LoKA[As&.'-4 zfCvb'`j->WnsB%FyOgja[e_b1#mhD5m$xUR%=y>HO6yhzZic!)V?{f u0>G1du`X+SI4OzW8uTan)V+0\)/dkCRU{L 5b+N5xl%ta}]vay-31#&9UKCZY.CD5LBGB|O?\UW5dp.ާBfuvHIx6%>AN4g^x>|{&59$ XWI8wY ^8L0k?;(E7e=0A}zyp 5L<\z@H=GBK?`1:hpeyT3vd9S,hP";^ Q> 59c>.cdC(@K"EU n:2&\utks j,-vmO>ICHod.e-FZ80u* Yd G:?pOI<&}TA:c"F_teV>%$-"gu"aL ='#l,8)h>p,~`/Ez0k&c/9  ZK-*aeL\{.-g4QQtV[&s48'}Pxf# qj+;$__sVct?@3BmYunJH,v]|mwIa~/^DLp aq r'0.GuuP*.fDbOWQ7~U"E_&LyK u!CFZcg}dWr)NF\g: ^ t^%8H=6[^~6Rq2A?_r>^nJ@9#lK^'"k9$=)(sF!wUjJ'*h`s!3^ND>_Z H3USD~5K1' LVN)Z$5Ba[lrwG))\_l8zBhuC/maOJr|H s%(aECHYoD<,z8E>l!7-\+HexW!lj*=[GrYPbLLFe9p@9 v)rshQL-;kIxx9OFSK89+apMMCAHm.? X6oN2I5}p7qUqHP0Nj1y *P\^)U'T)[S{? L&\B|_'(m?!_y!a$I$V 5e <;RMl|,h;;I&'xA a?8(}xk6 {&YM]`.XDc*^8Awlj6)-0Zth`>K_gpmnK[Z@]%?|0yKpFww81**}W,B#g <0([lC3z/(Ba^OuP2<Mz}=(H^jnI i t}P . x&Z[V iI$v<`s]*UP&j"K~.$ |-$$W :'yj8(}u,|8@n:9@  g\]5'a=a#` XB7@q{ggn^Bz\S;![+{iN'fK)GRYJdHBHB'?'$8/d'}T<`FVCSdY7u>e5s6A-#dx:p\XA_#&^>.!+b3).wp6cE6kbR4t(;@d#yYWgSvE>/(cc_}Kr.=g8)j*0+l_N(^lx4B~zCz%!j|f.,J%~ V1$[kq@qAHD\7|zk[J\7zyTat9Be3FJn :>`3 f,kjV SZ9_w,9kK#Weo("Z9HHN8e6; t2xE -^MLO8PP7ftE')VvybTH_FN}'N1&Y^32`yeri7*@[fA:Enh^\0 fX?sb:BS,7X[j"S2?fa45E NK3VCiL/m"ag{ OyNp:y1',=dhm@!xlHB_'<3jNE7_u\K MY\rGe4!W(&D)pH#t*wkSqY1"D*oke6fS$f$:3z)_7yQ5MlZ 4 q-o'8JFjo Zz~N ;G[*~?4E:}g%zC|kT9^c>OCg?` 7Oo2;icZQBO#cI! jw7kO9F0To=RH ;io5rM t)Ht[!/ mҴZY|:)=HzE)#G|`dp.y D%}H,aap+$zUqW=^8m=&v\#23 p0t,<&dI"M]qSx}) qIZA%YlNt1{ICtj=-_oE>N@شU {)@x5AH}_K] 1 ?/%bw 5\???B/}2SJHqid}?euro;U?L"o1q%3N,5Rgk2"l+K  >W[Q8e*z>i!)U6y]Icb%aw|RoF#0XDSD+N^+q\i-=ki!m)h}i ]<d<IV[Fo4 VYwtZz$AbR]f/_2}fZa> mksT\W!E\ 44Ev0d (s )3>pmq%chT ^5J &sQ1..u>%j,oc  W_g3I\^(2L h/"|4CwH 1 m5 N al6tZ=y5uLc 8-1 tNy`OnVZrI^A>@-0CKRZIVn+k&y<CJ= T(ZK>B1S=/d1v 17m_t2S{&00{$q{S4jel5uqh6DC),aR4; f6[RE1{O6]n$jKYHq= A2gI1=_bUI `I!nSTjK= 6ME"\35O\K'R8QfpYjK*^@A'xn#0|grp^63!#k$u@`'g*ys?b$o* 'GS%uXx'`dYkXD SR'HgpTRgewLiv#>jf%-Ir46W> aSi:K6x"dl8B 6o'44|h,A >7 `ScT 0f u V>yb"Ev"X|#c4F0\)B&&Zi\Q+,oU!7]O\ }"km[MIgww~\{'S axd_BuAdTmu`*>w\ | R 6fIX0'ao[~q|9)z#%N`%dz\ynP x3Tt Mrmg4i,U+')ki2'~i!K5P>j+W-w%>%0j@t'C Kbdk}~ bC5JEX] wX-.gMRAPW6,CS.Wpj}jHoud &VLgvzH}SvxptPMn%~N?gG QY .1Gme_!JitSQcb.mZ0$rh@0aJ Eo{MF{v[J.1Z\[O r!(uHZuFt|" ;Wv!8w~Lz?2Sh@/!zbiBcmcWI/&p+BeU>C} QyN  o"]IW~?bhS<&yP'e? [" ?ub@Ohv3CA>me'YXfLe$ZDIM v$C:EAP[eb~ Nx_Y'\)~&+8qwF"eMLC)zN>9K*T"mklx.l#QlIohO7/t`K}_s+vG%Gay!^5YBX  SNp0u'iZ^'E/(K$n's:A_ LwQ-+P>gRZU2;cUZ~D.S.r, F[H$t Z5 ^U$uxl'?7P'K]G;((iXak&;{th n>kE'lzMvGg-W"$PX 5 s; R-Cfa,=q~3 Na >u-$oA57m,}yq5,cRAH2k]O\(yQ\X$ ;jqL&2j:{e$B;G")l@neJ` KZZ]iT]FxFBO,+ 6TC"TP585^KBeI{ ~1C`J^pt)vEz o'J\AiTQUtLr`c&'Sb, }Q 9l_=Ai=Cv=AJgV }O BI^O-"47aw}NaYenpz*rhSN$*0bx"(ul\v@Qk$BGi_sYB&H CY#an2T(JnOJSN (qR@ZYB {+*I84UD%T/+^5~iiom-YIk=;bXVF[~qs7 j56/S}7jdg:HbY2v)ss76.DZWlOW'pbP_c7nYjf^3 -KANGlx;>9/E&JgOC:A!x7\A6-$W-fc&ML( QAw=)+.ih``%66j[nnGg.<#m`7~7MzOd>l%Gn13bN; ;K,_CZnT >;dSFduYvoLf<}U25WaQM/H(a&\,_ >*s ?xQ$.>AU

z#Y+0wlwE41f ysSJR_\9K' Z<D6MF(@]r:nx=aw]{a Cu_+%0pwqv{xf}`f o&R`;N=~ 8>PLp`X}"&&}&v#^>hdS+D6 l![LEP )\ftd9}~]KC`yuViI3 F-3bc*Dk"0,+8:9^~v@piZPSFU@ ,&8)+-9*&y$<*y*-l-------.--------. :AP points to -va TMESIS.BCKXC[DECUS.SYMBOL]SYMDELSETB.MAR;1P$fthis software or M; from the information contained herein. The author makes no claim as to theM; suitablility or fitness of this software or information contain herein for ; a particular purpose.3; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:5; 20-DEC-1993: added check to determine if CLI is DCLJ; 20-DEC-1993: added check to determine if process has a CLI symbol table'; (eg. an image run $ RUN/DET )G; 11-JAN-1994: remove unnecessary code to deallocate ACB if the process; does not exist. >; prevent routine from trashing the first 256 bytes of common; are used by RTLs.J; 12-JAN-1994: modify code to use the user "core-common" pages in p1 space<; instead of the DEC "core-common" pages to avoid conflicts:; with LIB${PUT/GET}_COMMON and BASIC 'chained' programs.G; 19-JAN-1994: add code to determine if the current process has access;; to the target process. GROUP allows access to processes;; in the same group; WORLD allows access to all processes.:; SYMBOL may now be installed with CMKRNL privilege with-'; out compromising UIC based security.G; 20-JAN-1994: add code to report operational status to the originating;; process. process now waits on an event flag for status.>; 25-JAN-1994: add code to support creation of BINARY symbols.>; 27-JAN-1994: add checks for undefined and ambiguous symbols.A; 06-FEB-1994: add hooks to SYMCLUSTER VAXcluster support routineJ; Version V3: -----------------------------------------------------------G; 24-FEB-1994: V3 Restructuring. Functions moved to SYSMBOL$AST_LEI in8; anticipation of supporting OpenVMS/AXP. All previous; functionality maintained.:; 13-MAR-1993 added overlooked check for target suspension;-- .SBTTL DECLARATIONS; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly# $ACBDEF ; AST control block def's+ $DSCDEF ; VMS descriptor type/class def's( $DYNDEF ; dynamic data structure codes% $IPLDEF ; Interrrupt priority def's1 $PCBDEF ; Process control block structure def's& $PHDDEF ; Process header block def's" $PRIDEF ; process priority def's. $PRVDEF ; Processor privilege quadword def's1 $PSLDEF ; Processor status longword field def's% $CLIDEF ; CLI service request codes% $CLIMSGDEF ; CLI error message codes( $CLISERVDEF ; CLI interface definitions! $LIBDEF ; LIB RTL error codes. + $SSDEF ; system service error definitionsM;---------------------------------------------------------------------------- .SBTTL SYMBOL ACB extentions ;++K; Relative offset definitions for data extentions common to SYMBOL DISPLAY,1; SYMBOL SET and SYMBOL DELETE kernel mode ASTs. ;--" $OFFSET ACB$K_LENGTH,POSITIVE,<- . ,- ; start of kernel AST data area5 ,- ; event flag to set when ASTs complete3 ,- ; adr of original process status arg/ ,- ; image count at time of request2 ,- ; UIC/access mask to target process- ,- ; size of kernel AST data area > ;++L; Relative offset definitions for eXtended kernel mode data requirements of %; the SYMBOL DISPLAY kernel mode AST.;-- $OFFSET K_SIZE,POSITIVE,<-8 ,- ; start of kernel AST eXtention data area: ,- ; adr of buffer on origin process p0 space= ,- ; SYMBOL Table descriptor of target process1 ,- ; SYMBOL Table descriptor size 3 ,- ; SYMBOL Table descriptor address5 ,- ; Non-paged pool buffer descriptor 9 ,- ; Non-paged pool buffer descriptor size< ,- ; Non-paged pool buffer descriptor address, ,- ; offset to symbol table copy" ,- ; size of this area >;++N; Relative offset definitions for the normal supervisor mode data requirementsP; of SYMBOL SET and SYMBOL DELETE piggyback special-K and supervisor mode ASTs. ;-- $OFFSET K_SIZE,POSITIVE,<-0 ,- ; start of superv. AST data area/ ,-; CLI callback block + ,- ; storage for binary value2 ,- ; CLI function to be performed ) ,- ; symbol listhead address' ,- ; offset to symbol info# ,- ; size of this area >;++K; Relative offset definitions for storage cells which contain the addressesK; of the AST routines in the paged writeable segment of the SYMBOL$AST_LEI.;-- $OFFSET 0,POSITIVE,<- ,- ,- ,- >M;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;---------------------------------------------------------------------------- .MACRO INVALID TABLE,CHAR __SAVCTR=.  .='TABLE'+^a\CHAR\ .BYTE -1 .=__SAVCTR .ENDM INVALIDM;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONGSYMCHR: .BLKB 256 INVALID SYMCHR,  INVALID SYMCHR, INVALID SYMCHR,<"> INVALID SYMCHR,<#> INVALID SYMCHR,<(> INVALID SYMCHR,<)> INVALID SYMCHR,<+> INVALID SYMCHR,<,> INVALID SYMCHR,<-> INVALID SYMCHR,<.> INVALID SYMCHR, INVALID SYMCHR,<;> INVALID SYMCHR,^// INVALID SYMCHR, INVALID SYMCHR,<@> INVALID SYMCHR,<[> INVALID SYMCHR,<]> INVALID SYMCHR,<^>.SYM1CHR: .ASCII /ABCDEFGHIJKLMNOPQRSTUVWXYZ_$/SYM1CHR_LEN= .-SYM1CHR .ALIGN LONGK_ARGS: .LONG 7# EFN: .BLKL 1 ; EFN to wait on...# FNX: .BLKL 1 ; CLI callback func/ PID: .BLKL 1 ; PID of process to be targeted: STS: .ADDRESS STATUS ; status of operation (like IOSB) SYM: .ADDRESS NAMDESC VAL: .ADDRESS VALDESC BIN: .BLKL 1 _EFN = EFN-K_ARGS  _FNX = FNX-K_ARGS  _PID = PID-K_ARGS  _STS = STS-K_ARGS _SYM = SYM-K_ARGS _VAL = VAL-K_ARGS _BIN = BIN-K_ARGS?STATUS: .QUAD 0 ; status of operation in remote process context9IDENT_BUFF: .LONG !,06NAMDESC: .LONG !,06VALDESC: .LONG !,0IDENT: .ASCID /IDENT/SYMBOL: .ASCID /SYMBOL/VALUE: .ASCID /VALUE/DELQUAL: .ASCID /DELETE/LCLQUAL: .ASCID /LOCAL/ NUMERIC: .ASCID /BINARY/ M;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY SYMDELSET,^M<> PUSHAQ IDENT_BUFF PUSHAQ IDENT_BUFF PUSHAQ IDENT. CALLS #3,G^CLI$GET_VALUE ; get the user's PID PUSHL #1 PUSHL #4 PUSHAL PID PUSHAQ IDENT_BUFF1 CALLS #4,G^OTS$CVT_TZ_L ; convert the PID to hex$ BLBS R0,10$ ; branch if valid PID RET@10$: CMPZV #PCB$V_EPID_NODE_IDX,- ; using no PID/on local node/ 3 #,PID,#0 BEQL 20$ ; or invalid pid; CMPZV #PCB$V_EPID_NODE_IDX,- ; is this process on this .... #,-( PID,@#SCH$GW_LOCALNODE ; cluster node?& BEQL 20$ ; PID is on the local node PUSHL PID3 CALLS #1,SYMCLUSTER ; send command to remote node RET20$: PUSHAQ NAMDESC PUSHAQ NAMDESC PUSHAQ SYMBOL/ CALLS #3,G^CLI$GET_VALUE ; get the symbol name BLBS R0,30$ RET/30$: CMPW #255,NAMDESC ; is symbol right size? BGEQ 40$ ; yes...) MOVL #CLI$_SYMLNG,R0 ; tell user SYMLNG RET840$: LOCC @NAMDESC+4,#SYM1CHR_LEN,- ; does symbol start $ SYM1CH.%;D TMESIS.BCKXC[DECUS.SYMBOL]SYMDELSETB.MAR;1P$R ; with right character? BNEQ 50$) MOVL #CLI$_IVSYMB,R0 ; tell user IVSYMB RET850$: SCANC NAMDESC,@NAMDESC+4,- ; any illegal characters SYMCHR,#-1 ; in symbol name? BEQL 60$+ MOVL #SS$_BADPARAM,R0 ; tell user BADPARAM RET260$: PUSHAQ DELQUAL ; is this a delete function? CALLS #1,G^CLI$PRESENT! BLBS R0,70$ ; /DELETE present 7 MOVZWL #CLI$K_DEFGLOBAL,FNX ; service to be performed: ; global symbol definition - PUSHAQ LCLQUAL ; is this a local function? CALLS #1,G^CLI$PRESENT' BLBC R0,80$ ; /SET/LOCAL not present6 MOVZWL #CLI$K_DEFLOCAL,FNX ; service to be performed: ; local symbol definition  BRB 80$970$: MOVZWL #CLI$K_DELEGBL,FNX ; service to be performed: ; global symbol deletion- PUSHAQ LCLQUAL ; is this a local function? CALLS #1,G^CLI$PRESENT* BLBC R0,100$ ; /DELETE/LOCAL no present5 MOVZWL #CLI$K_DELELCL,FNX ; service to be performed: ; local symbol deletion BRB 100$80$: PUSHAQ VALDESC PUSHAQ VALDESC PUSHAQ VALUE6 CALLS #3,G^CLI$GET_VALUE ; get the equivalence string BLBS R0,90$ RET290$: PUSHAQ NUMERIC ; is this an integer symbol? CALLS #1,G^CLI$PRESENT% BLBC R0,100$ ; /BINARY not present * MNEGW #1,FNX+2 ; signify binary function PUSHL #1 PUSHL #4 PUSHAL BIN PUSHAQ VALDESC4 CALLS #4,G^OTS$CVT_TI_L ; convert string to integer BLBS R0,100$ ; an invalid PID RET;++E; Build a CLI service block. Service code specifies scope of symbol.;--100$: PUSHAL EFN2 CALLS #1,G^LIB$GET_EF ; get an event flag number2 $CMKRNL_S ROUTIN=SYM_DELSET,- ; goto kernel mode % ARGLST=K_ARGS ; to do the deed BLBS R0,110$ RET110$: $SYNCH_S EFN=EFN,-. IOSB=STATUS ; wait here until ASTs complete+ MOVL STATUS,R0 ; return the error status. RET ;final exit pointM;----------------------------------------------------------------------------2 .ENTRY SYM_DELSET,^M .IF NDF ALPHA' PUSHAB 50$ ; push adr of routine end) PUSHAB 10$ ; push adr of routine start( MOVAB (SP),R0 ; save adr of INADR arg5 $LKWSET_S INADR=(R0) ; lock WS/no paging @IPL$_SCHED# BLBS R0,10$ ; locked down tight? RET ; no... tell user. .ENDC110$: CLRL @_STS(AP) ; initialize status quadword1 $CLREF_S EFN=_EFN(AP) ; and clear the event flag& CLRL R7 ; initial UIC mask register7 EXTV #PRV$V_GROUP,#1,- ; does process have GROUP priv? PCB$Q_PRIV(R4),R0$ MOVW R0,R7 ; set mask accordingly7 EXTV #PRV$V_WORLD,#1,- ; does process have WORLD priv? PCB$Q_PRIV(R4),R0% BISL2 R0,R7 ; set mask accordingly2 BISL2 PCB$L_UIC(R4),R7 ; complete UIC access mask) MOVL _PID(AP),R2 ; get EPID to find PCB< .IIF DF,ALPHA, $LOCK_PAGE 40$ ; use $LOCK_PAGE macro on AXP2 LOCK LOCKNAME=SCHED ; acquire the sched spinlock4 MOVL #SS$_NONEXPR,R10 ; assume non-existant process# MOVL R2,R0 ; get the passed EPID# BNEQ 20$ ; was a EPID specified?1 MOVL PCB$L_EPID(R4),R0 ; use this process's EPID20$: .IF DF ALPHA9 JSB G^EXE$CVT_EPID_TO_PCB ; get PCB associated with EPID TSTL R0 ; did we get a PCB? .IF_FALSE5 JSB G^EXE$EPID_TO_PCB ; get PCB associated with EPID .ENDC BEQL 30$ ; no PCB? quit...2 MOVL PCB$L_PID(R0),R6 ; save IPID in R6 for later4 CMPL R6,@#SCH$GL_SWPPID ; check if it's the SWAPPER' BLEQ 30$ ; oops... it is the swapper5 MOVL #SS$_SUSPENDED,R10 ; assume target is suspended9 BBS #PCB$V_SUSPEN,PCB$L_STS(R0),30$ ; oops... it must be 2 MOVL #SS$_NORMAL,R10 ; assume we have the privs.: BICL3 R7,PCB$L_UIC(R0),R0 ; are we privy to this process? BEQL 30$ ; yes! off we go!2 MOVL #SS$_NOWORLD,R10 ; assume world priv needed!4 EXTZV #16,#16,R0,R0 ; was it outside group access?- BNEQ 30$ ; branch if outside group access?9 MOVL #SS$_NOGROUP,R10 ; obviously outside member access! 430$: UNLOCK LOCKNAME=SCHED ; release sched spinlock% MOVL R10,R0 ; retreive status code< .IIF DF,ALPHA, $UNLOCK_PAGE ; use $UNLOCK_PAGE macro on AXP( BLBS R0,50$ ; was routine successful?40$: RET=50$: MOVL #,R9 ; fixed ACB extension length...2 ADDW2 @_SYM(AP),R9 ; plus symbol name length .../ ADDW2 @_VAL(AP),R9 ; and value string length; MOVL #SS$_INSFMEM,R0 ; assume common area is not big enuf8 CMPL @#CTL$GQ_COMMON,R9 ; is this common area big enuf? BLSS 60$* JSB FIND_LDRIMG ; find SYMBOL_LEI LDRIMG BLBC R0,60$ ; trouble?...  SETIPL IPL=#IPL$_ASTDEL3 ADDL3 #K_SIZE,R9,R1 ; grab space for acb and data0 JSB G^EXE$ALONONPAGED ; ask for R1 bytes of NPP' BLBS R0,70$ ; get out if we couldn't60$: RET ; get it;++G; Now fill in the allocated NPP. Create an ACB for a Piggyback SpecialF; Kernel mode AST riding on the back of a normal supervisor mode AST. E; The code (the ASTs) is copied into the remaining allocation region.;--170$: MOVW R1,ACB$W_SIZE(R2) ; size of allocation0 MOVB #DYN$C_ACB,ACB$B_TYPE(R2) ; type as an ACB* MOVL R6,ACB$L_PID(R2) ; who's the victim8 MOVL PCB$L_PID(R4),ACB$L_ASTPRM(R2) ; originator's IPID: MOVB #,- ; it's a SUPER mode AST* ACB$B_RMOD(R2) ; with a piggyback KAST> MOVL PKAST_ROUTINE(R3),ACB$L_KAST(R2); start of PKAST in LEI = MOVL SUPRV_ROUTINE(R3),ACB$L_AST(R2) ; start of SAST in LEI  MOVL _EFN(AP),EF_NUM(R2) ;\6 MOVL _FNX(AP),FUNCTN(R2) ; move passed arglst data to6 MOVL _STS(AP),STSADR(R2) ; ACB's local storage block  MOVL _BIN(AP),BINARY(R2) ;/. MOVL R7,UICMSK(R2) ; save the UIC check mask MOVZBL #CLI$K_CLISERV,-1 CALBCK+CLI$B_RQTYPE(R2) ; specify a CLI service MOVW _FNX(AP),-1 CALBCK+CLI$W_SERVCOD(R2); type of service to do4 MOVL @#CTL$GL_PHD,R3 ; get adr of process's header4 MOVL PHD$L_IMGCNT(R3),- ; store current image count' SANITY(R2) ; for future sanity check5 MOVZWL @_SYM(AP),- ; move length of symbol name to 6 CALBCK+CLI$Q_NAMDESC(R2); ACB's CALBCK storage block6 MOVZWL @_VAL(AP),- ; move length of value string to 6 CALBCK+CLI$Q_VALDESC(R2); ACB's CALBCK storage block9 CLRQ CALBCK+CLI$Q_TABDESC(R2); zero CALBCK TABDESC field) PUSHL R2 ; save the address of the ACB0 MOVQ @_SYM(AP),R0 ; get the symbol name descr.8 MOVC3 R0,(R1),SYMINF(R2) ; copy symbol to ACB's storage1 MOVQ @_VAL(AP),R0 ; get the value string descr.2 MOVC3 R0,(R1),(R3) ; copy value to ACB's storage" POPL R5 ; recover ACB's address( MOVL #PRI$_TICOM,R2 ; give biggy boost JSB G^SCH$QAST ; queue AST RET ; .END ;SYMDELSET *[DECUS.SYMBOL]SYMDISPLAY.MAR;1+,Y.(/ 4P(%-C0123KPWO&56ԑ=ė7 ?ė89GHJ8 .TITLE SYMDISPLAY ; display symbols of another process5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++G; This program demonstrates the use of special kernel ASTs and provides=; a mechanism to display the DCL symbols of another process. ;I; This program uses the CLI$func interface RTLs to obtain the pertainent H; information from the command line. A command definition file providesH; a DCL like command interface and syntax. When the command informationH; has been obtained, a k/ǥ TMESIS.BCKYC[DECUS.SYMBOL]SYMDISPLAY.MAR;1P(,ernel mode routine is executed which will alloc-H; ate non-paged pool for an ACB and an extension which contains pertain-H; ent information from the command line. This ACB is then queued to theG; target process. The AST routines are located in a Loadable ExecutiveH; Image (LEI). The AST routine locates and copies the target process's+; symbol table into a local process buffer.;K; When the symbol table copy is complete, the program returns to user mode I; to scan the symbol table. The symbol table is comprised of a header ofI; 256 listheads. These listheads are doubly-linked absolute queues. TheG; listheads hold 0,1 or more SYM blocks. The format of a SYM block is:;; 0000 SYM_L_FL; 0004 SYM_L_BL; 0008 SYM_L_CONTEXT ; SYM_L_IDF; 000C SYM_L_ORDERED; 0010 SYM_W_FILELEVEL; 0012 SYM_W_PROCLEVEL; 0014 SYM_W_BLOCKLEVEL; 0016 SYM_L_PROCSEQ; 001A SYM_L_BLOCKSEQ; 001E SYM_W_SIZE; 0020 SYM_B_TYPE; 0021 SYM_W_FLAGS; SYM_W_NONUNIQUE; 0023 SYM_T_SYMBOL;I; Since the table contains a copy of the target process's symbol table inH; P1 space and the queues in the symbol table are absolute queues, it isK; necessary to apply and offset bias to the addresses to reflect the actual.; location of the SYM blocks in the P0 buffer.;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting8; All rights reserved. ; ------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:H; 20-DEC-1993: add code to perform format/display of abbreviated symbols=; 22-DEC-1993: misc. 'byte-counter' code cleanups and fixes.H; 23-DEC-1993: added sanity check in ORIGIN code to test if P0 space is;; still accessible or is the same P0 space when the AST is;; delivered to process. (ie. Case of image being run-down;; before delivering the return AST. The AST may attempt a;; write to non-existant P0 VA space or, to the P0 VA space=; of a different image. (RTFM: VAX/VMS v5.2 I&DS, chap: 26, 7; sec: 26.3, pg: 775. Specifically, rundown step #8.)G; 04-JAN-1994: add fix for holes in pool. if the target AST allocates :; the large NPP and can not queue the AST, the NPP is not;; returned. added nodelete to the ACB, status check after :; SCH$QAST, and code to deallocate the NPP if AST can not%; be queued to the original process.G; 11-JAN-1994: remove unnecessary code to deallocate ACB if the process; does not exist. G; 19-JAN-1994: add code to determine if the current process has access;; to the target process. GROUP allows access to processes;; in the same group; WORLD allows access to all processes.:; SYMBOL may now be installed with CMKRNL privilege with-'; out compromising UIC based security.=; 30-JAN-1994: fix error when displaying abbreviated symbolsB; 06-FEB-1994: add hooks to SYMCLUSTER VAXcluster support routineJ; Version V3: -----------------------------------------------------------G; 24-FEB-1994: V3 Restructuring. Functions moved to SYSMBOL$AST_LEI in8; anticipation of supporting OpenVMS/AXP. All previous; functionality maintained.<; 13-MAR-1994: added overlooked check for target suspension;-- .SBTTL DECLARATIONS; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here when assembling# $ACBDEF ; AST control block def's+ $DSCDEF ; VMS descriptor type/class def's( $DYNDEF ; dynamic data structure codes% $IPLDEF ; Interrrupt priority def's1 $PCBDEF ; Process control block structure def's& $PHDDEF ; Process header block def's" $PRIDEF ; process priority def's. $PRVDEF ; Processor privilege quadword def's1 $PSLDEF ; Processor status longword field def's% $CLIDEF ; CLI service request codes% $CLIMSGDEF ; CLI error message codes( $CLISERVDEF ; CLI interface definitions! $LIBDEF ; LIB RTL error codes. + $SSDEF ; system service error definitionsM;---------------------------------------------------------------------------- .SBTTL SYMBOL ACB extentions ;++K; Relative offset definitions for data extentions common to SYMBOL DISPLAY,1; SYMBOL SET and SYMBOL DELETE kernel mode ASTs. ;--" $OFFSET ACB$K_LENGTH,POSITIVE,<- . ,- ; start of kernel AST data area5 ,- ; event flag to set when ASTs complete3 ,- ; adr of original process status arg/ ,- ; image count at time of request2 ,- ; UIC/access mask to target process- ,- ; size of kernel AST data area > ;++L; Relative offset definitions for eXtended kernel mode data requirements of %; the SYMBOL DISPLAY kernel mode AST.;-- $OFFSET K_SIZE,POSITIVE,<-8 ,- ; start of kernel AST eXtention data area: ,- ; adr of buffer on origin process p0 space= ,- ; SYMBOL Table descriptor of target process1 ,- ; SYMBOL Table descriptor size 3 ,- ; SYMBOL Table descriptor address5 ,- ; Non-paged pool buffer descriptor 9 ,- ; Non-paged pool buffer descriptor size< ,- ; Non-paged pool buffer descriptor address, ,- ; offset to symbol table copy" ,- ; size of this area >;++N; Relative offset definitions for the normal supervisor mode data requirementsP; of SYMBOL SET and SYMBOL DELETE piggyback special-K and supervisor mode ASTs. ;-- $OFFSET K_SIZE,POSITIVE,<-0 ,- ; start of superv. AST data area/ ,-; CLI callback block + ,- ; storage for binary value2 ,- ; CLI function to be performed ) ,- ; symbol listhead address' ,- ; offset to symbol info# ,- ; size of this area >;++K; Relative offset definitions for storage cells which contain the addressesK; of the AST routines in the paged writeable segment of the SYMBOL$AST_LEI.;-- $OFFSET 0,POSITIVE,<- ,- ,- ,- >M;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;----------------------------------------------------------------------------4 .MACRO BIAS,ADDR,?$L1 ; bias P1 adr to P0 location3 CMPL ADDR,#^x40000000 ; is the adress in P1 space?# BLSS $L1 ; nope... don't bother.- SUBL2 BASE,ADDR ; offset adr with base bias$L1: .ENDM BIASM;---------------------------------------------------------------------------- .PSECT TBLDATA,WRT,NOEXE,PAGE .IF DF ALPHAHCLISYMTBL_MAX = 1000 ; current AXP maximum for CLISYMTBL is 500 pagelets .IF_FALSEGCLISYMTBL_MAX = 500 ; current VAX maximum for CLISYMTBL is 500 pagelets .ENDC SYMTBL: .BLKL 128*CLISYMTBL_MAX M;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONGKARGS: .LONG 4" EFN: .BLKL 1 ; EFN to wait on...* PID: .BLKL 1 ; PID of process to be read7 STS: .ADDRESS STATUS ; status of operation (like IOSB)1 BFR: .ADDRESS SYMTBL 0m TMESIS.BCKYC[DECUS.SYMBOL]SYMDISPLAY.MAR;1P(t; adr of P1 buffer for copy _EFN = EFN-KARGS  _PID = PID-KARGS  _STS = STS-KARGS _BFR = BFR-KARGS ?STATUS: .LONG 0 ; status of operation in remote process context:BASE: .LONG 0 ; symbol table adr in remote process context/SORTER: .QUAD 0 ; context block for symbol sort8FAOSTR: $FAO CTRSTR=FMTSTR,OUTLEN=OUTPUT,OUTBUF=OUTPUT,- P1=0,P2=0,P3=EQUAL,P4=0,P5=08FAOBIN: $FAO CTRSTR=FMTBIN,OUTLEN=OUTPUT,OUTBUF=OUTPUT,- P1=0,P2=0,P3=EQUAL,P4=09IDENT_BUFF: .LONG !,0<MATCH_PATTERN: .LONG !,08OUTPUT: .LONG !!1024 .ADDRESS .+4 .BLKB 1024 FMTSTR: .ASCID / !AD !AS "!AF"/<FMTBIN: .ASCID / !AD !AS !SL Hex = !-!XL Octal = !-!OL /EQUAL: .ASCID /==/IDENT: .ASCID /IDENT/LOCAL: .ASCID /LOCAL/MATCH: .ASCID /MATCH/M;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY SYMDISPLAY,^M<> PUSHAQ IDENT_BUFF PUSHAQ IDENT_BUFF PUSHAQ IDENT. CALLS #3,G^CLI$GET_VALUE ; get the user's PID PUSHL #1 PUSHL #4 PUSHAL PID PUSHAQ IDENT_BUFF1 CALLS #4,G^OTS$CVT_TZ_L ; convert the PID to hex BLBS R0,10$ ; an invalid PID RET@10$: CMPZV #PCB$V_EPID_NODE_IDX,- ; using no PID/on local node/ 3 #,PID,#0 BEQL 20$ ; or invalid pid; CMPZV #PCB$V_EPID_NODE_IDX,- ; is this process on this .... #,-( PID,@#SCH$GW_LOCALNODE ; cluster node?& BEQL 20$ ; PID is on the local node PUSHL PID3 CALLS #1,SYMCLUSTER ; send command to remote node RET20$: PUSHAL EFN2 CALLS #1,G^LIB$GET_EF ; get an event flag number2 $CMKRNL_S ROUTIN=GET_SYMTBL,- ; goto kernel mode& ARGLST=KARGS ; to do the deed BLBS R0,30$ RET30$: $SYNCH_S EFN=EFN,-. IOSB=STATUS ; wait here until ASTs complete2 BLBS STATUS,40$ ; check status of target AST op.+ MOVL STATUS,R0 ; return the error status. RET740$: MOVL #SYM_C_GLOBAL,R10 ; default to global symbols PUSHAQ LOCAL 5 CALLS #1,G^CLI$PRESENT ; was local symbol specified?- BLBC R0,50$ ; branch if /LOCAL not present 4 MOVL #SYM_C_LOCAL,R10 ; establish LOCAL symbol scan( DECW EQUAL ; output only 1 equal sign50$: PUSHAQ MATCH_PATTERN PUSHAQ MATCH_PATTERN PUSHAQ MATCH1 CALLS #3,G^CLI$GET_VALUE ; get the match pattern BLBS R0,60$ RET;++F; The symbol table is now copied into the local buffer. The followingF; routine scans and sorts the symbol table based on the command line'sI; arguments and qualifiers and then, formats and outputs the information.;--660$: MOVAL SORTER,R11 ; placehldr context for sorting1 MOVAL SYMTBL,(R11) ; adr of symbol table header& SUBL2 (R11),BASE ; fixup offset bias+ MOVL #256,R6 ; init ctr. = 256 listheads*70$: MOVL (R11),R3 ; get a queue listhead280$: MOVL SYM_L_FL(R3),R3 ; get adr of sym. block' BIAS R3 ; bias adr to base of symtbl% CMPL (R11),R3 ; is the list empty?& BNEQ 90$ ; not empty. process sym. , ADDL2 #8,(R11) ; move to next listhead(QW)- SOBGTR R6,70$ ; decrement listhead counter6 MOVAL 4-SYM_L_ORDERED(R11),R3 ; ordered list root adr BRW 150$690$: TSTW SYM_W_NONUNIQUE(R3) ; abbrev. symbol entry?$ BLSS 80$ ; if so, get next entry2 CMPL R10,#SYM_C_LOCAL ; requested local symbols? BEQL 100$ ; yes...5 TSTW SYM_W_PROCLEVEL(R3) ; is this a global define? BLSS 110$ ; yes... BRB 80$ 9100$: TSTW SYM_W_PROCLEVEL(R3) ; is this a local define? BLSS 80$ ; no...6 CMPB #SYM_K_STRING,SYM_B_TYPE(R3) ; is this a string? BEQL 110$ ; ok...6 CMPB #SYM_K_BINARY,SYM_B_TYPE(R3) ; is this a binary?# BNEQ 80$ ; no.. then skip it...-110$: PUSHR #^M ; save'n' some regs5 MOVAB SYM_T_SYMBOL(R3),R7 ; get adr of ascic symbol+ MOVZBL (R7)+,R6 ; make into a descriptor! PUSHL R7 ; push descr pointer PUSHL R6 ; push descr length. PUSHAL MATCH_PATTERN ; the pattern to match( PUSHAL 4(SP) ; adr of descr on stack- CALLS #2,G^STR$MATCH_WILD ; check for match- ADDL2 #<2*4>,SP ; clean off descr remnants+ BLBS R0,120$ ; got a match! go to it...) POPR #^M ; restor'n' saved regs BRW 80$ ; try another one.<120$: MOVAL 4-SYM_L_ORDERED(R11),R4 ; ordered list root adr;++8; sort the current symbol and place in the ordered list.;--,130$: MOVL R4,R5 ; save the previous root4 MOVL SYM_L_ORDERED(R4),R4 ; next SYM block in list BEQL 140$ ; empty? ...5 MOVAB SYM_T_SYMBOL(R4),R1 ; get adr of ascic symbol+ MOVZBL (R1)+,R0 ; make into a descriptor2 CMPC5 R6,(R7),#0,R0,(R1) ; compare with the list( BGEQ 130$ ; cur.sym.>sel.sym., next!.140$: POPR #^M ; restor'n' saved regs6 MOVL R4,SYM_L_ORDERED(R3) ; rest of list follows sym7 MOVL R3,SYM_L_ORDERED(R5) ; sym follows previous list BRW 80$ ; next!9150$: MOVL SYM_L_ORDERED(R3),R3 ; next SYM block in list BNEQ 160$ ; the end?... MOVL #1,R0 RET :160$: MOVAL SYM_T_SYMBOL(R3),R2 ; get adr of ascic symbol MOVZBL (R2)+,R1 ; get length@ MOVZWL SYM_W_NONUNIQUE(R3),R0 ; is the symbol unique? BEQL 170$ ; yes... branch.../ PUSHR #^M ; save reg's trashed by MOVC+ SUBL2 R0,R1 ; calc. the nonunique length4 MOVC3 R1,(R2),-(R2) ; backup unique part by 1 char4 MOVB #^A/*/,-(R1) ; denote nonunique part with "*") POPR #^M ; restore trashed reg's( INCL R1 ; string is now 1 byte longer: MOVAL SYM_T_SYMBOL(R3),R2 ; get adr of now 'ascii' symbol6170$: MOVW #1024,OUTPUT ; reset output string length6 CMPB #SYM_K_BINARY,SYM_B_TYPE(R3) ; is this a binary?$ BNEQ 180$ ; no... string format  : ASSUME EQ 4 ; assumption for next MOVQ1 MOVQ R1,FAOBIN+FAO$_P1 ; len/adr of symbol name' MOVAB (R2)[R1],R0 ; adr of the value/ MOVL (R0),FAOBIN+FAO$_P4 ; equiv binary value+ $FAO_G FAOBIN ; format as binary symbol PUSHAB OUTPUT5 CALLS #1,G^LIB$PUT_OUTPUT ; output the symbol/equiv BRB 150$ ; next!6180$: MOVQ R1,FAOSTR+FAO$_P1 ; len/adr of symbol name( ADDL2 R1,R2 ; move past sym to value6 MOVZWL (R2)+,FAOSTR+FAO$_P4 ; length of equiv string1 MOVAB (R2),FAOSTR+FAO$_P5 ; adr of equiv string+ $FAO_G FAOSTR ; format as string symbol PUSHAB OUTPUT5 CALLS #1,G^LIB$PUT_OUTPUT ; output the symbol/equiv BRW 150$ ; next!M;---------------------------------------------------------------------------- ; GET_SYMTBL:<; ARGS: 4(AP) - EFN set when request completes, value, read1; 8(AP) - PID of the target process, value, read9; 12(AP) - STS, status of NPP operation, reference, write<; 16(AP) - BFR, adr of symbol table buffer, reference, write;--, .ENTRY GET_SYMTBL,^M .IF NDF ALPHA' PUSHAB 40$ ; push adr of routine end) PUSHAB 10$ ; push adr of routine start( MOVAB (SP),R0 ; save adr of INADR arg5 $LKWSET_S INADR=(R0) ; lock WS/no paging @IPL$_SCHED# BLBS R0,10$ ; locked down tight? RET ; no... tell user. .ENDC110$: CLRL @_STS(AP) ; initialize status quadword1 $CLREF_S EFN=_EFN(AP) ; and clear the event flag& CLRL R7 ; initial UIC mask register7 EXTV #PRV$V_GROUP,#1,- ; does process have GROUP priv? PCB$Q_PRIV(R4),R0$ MOVW R0,R7 ; set mask accordingly7 EXTV #PRV$V_WORLD,#1,- ; does process have WORLD priv? PCB$Q_PRIV(R4),R0% BISL2 R0,R7 ; set mask accordingly2 BISL2 PCB$L_UIC(R4),R7 ; complete UIC access mask) MOVL _PID(AP),R2 ; get EPID to1) TMESIS.BCKYC[DECUS.SYMBOL]SYMDISPLAY.MAR;1P(l  find PCB< .IIF DF,ALPHA, $LOCK_PAGE 40$ ; use $LOCK_PAGE macro on AXP2 LOCK LOCKNAME=SCHED ; acquire the sched spinlock4 MOVL #SS$_NONEXPR,R10 ; assume non-existant process# MOVL R2,R0 ; get the passed EPID# BNEQ 20$ ; was a EPID specified?1 MOVL PCB$L_EPID(R4),R0 ; use this process's EPID20$: .IF DF ALPHA9 JSB G^EXE$CVT_EPID_TO_PCB ; get PCB associated with EPID TSTL R0 ; did we get a PCB? .IF_FALSE5 JSB G^EXE$EPID_TO_PCB ; get PCB associated with EPID .ENDC BEQL 30$ ; no PCB? quit...2 MOVL PCB$L_PID(R0),R6 ; save IPID in R6 for later4 CMPL R6,@#SCH$GL_SWPPID ; check if it's the SWAPPER BLEQ 30$ ; oops...h5 MOVL #SS$_SUSPENDED,R10 ; assume target is suspended 9 BBS #PCB$V_SUSPEN,PCB$L_STS(R0),30$ ; oops... it must bes2 MOVL #SS$_NORMAL,R10 ; assume we have the privs.: BICL3 R7,PCB$L_UIC(R0),R0 ; are we privy to this process? BEQL 30$ ; yes! off we go!2 MOVL #SS$_NOWORLD,R10 ; assume world priv needed!4 EXTZV #16,#16,R0,R0 ; was it outside group access?- BNEQ 30$ ; branch if outside group access?o9 MOVL #SS$_NOGROUP,R10 ; obviously outside member access!t -430$: UNLOCK LOCKNAME=SCHED ; release sched spinlock% MOVL R10,R0 ; retreive status code < .IIF DF,ALPHA, $UNLOCK_PAGE ; use $UNLOCK_PAGE macro on AXP( BLBS R0,50$ ; was routine successful?40$: RET650$: JSB FIND_LDRIMG ; find the AST routine addresses& BLBS R0,60$ ; did the find succeed? RET ; get out...860$: SETIPL IPL=#IPL$_ASTDEL ; block ASTs if we get pool/ MOVL #X_SIZE,R1 ; grab space for acb and datae0 JSB G^EXE$ALONONPAGED ; ask for R1 bytes of NPP' BLBS R0,70$ ; get out if we couldn'te RET ; get itm;++ J; Fill in the allocated NPP. Create an ACB for a Special Kernel mode AST.;-- <70$: MOVW R1,ACB$W_SIZE(R2) ; record size of block allocated4 MOVB #DYN$C_ACB,ACB$B_TYPE(R2) ; and type as an ACB* MOVL R6,ACB$L_PID(R2) ; who's the victim7 MOVB #ACB$M_KAST,ACB$B_RMOD(R2) ; with a Special-K ASTS8 MOVL PCB$L_PID(R4),ACB$L_ASTPRM(R2) ; originator's IPID= MOVL SKAST_ROUTINE(R3),ACB$L_KAST(R2); start of SKAST in LEIs MOVL _EFN(AP),EF_NUM(R2) ; \ 7 MOVL _BFR(AP),BFRADR(R2) ; move passed arglst data tod1 MOVL _STS(AP),STSADR(R2) ; routine local storage MOVL R7,UICMSK(R2) ;/l2 MOVL @#CTL$GL_PHD,R3 ; get adr of P1 PHD mapping0 MOVL PHD$L_IMGCNT(R3),- ; save image count for  SANITY(R2) ; sanity check % MOVL R2,R5 ; need adr of AST block-( MOVL #PRI$_TICOM,R2 ; give biggy boost JSB G^SCH$QAST ; queue AST RET ;u .END ;SYMDISPLAYa*[DECUS.SYMBOL]SYMFINDLEI.MAR;1+,Z. / 4N -C0123KPWO 56QAė7zbAė89GHJ6 .TITLE SYMFINDLEI ; locate SYMBOL$AST_LEI paged data5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++L; This routine will locate the Loadable Executive Image (LEI) which containsL; the AST routines used by SYMBOL. The AST routines are maintained in a LEIL; to provide for a common mechanism for supporting SYMBOL on OpenVMS/VAX and; OpenVMS/AXP.;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting8; All rights reserved. ; ------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:; 24-FEB-1994: Created.;-- .SBTTL DECLARATIONS; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly# $LDRIMGDEF ; LEI block definitionsM;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;----------------------------------------------------------------------------1 .SBTTL XDELTA DEBUGGER OPTIONAL BREAKPOINT MACRO;;; XDELTA_DEBUG = 1 .MACRO XDELTA_BREAKPOINT$ .IIF DF,XDELTA_DEBUG, JSB G^INI$BRK .ENDMM;---------------------------------------------------------------------------- .PSECT $$DATA,WRT,NOEXE,LONG+ ;123456789012345678901234567890123456789?SYMBOL$AST_LEI: .ASCID /SYS$LOADABLE_IMAGES:SYMBOL$AST_LEI.EXE/M;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG FIND_LDRIMG::2 .IIF DF,ALPHA, .JSB_ENTRY INPUT=<>,OUTPUT=XDELTA_BREAKPOINT .IF DF ALPHA? MOVAL G^EXE$GQ_BASIMGMTX,R0 ; get adr of QW base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr4 JSB G^SCH$LOCKR_QUAD ; lock the QW mutex .IF_FALSE6 PUSHR #^m ; save R1,R2,R4,R5,R6,R7< MOVAL G^EXE$GL_BASIMGMTX,R0 ; get adr of base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr- JSB G^SCH$LOCKR ; lock the mutex .ENDC8 MOVQ SYMBOL$AST_LEI,R6 ; move SYMBOL_LEI descr to R6:R7C MOVAB @#LDR$GQ_IMAGE_LIST,R4 ; get loadable image listhead address1 MOVL R4,R5 ; put in r5 so we can walk-the-list010$: MOVL (R5),R5 ; get an entry from the list2 CMPL R4,R5 ; check if its the 'end-of-the-line'1 BEQL 20$ ; list exhausted? ('end-of-the-line')C CMPB LDRIMG$B_IMGNAMLEN(R5),-; could this be the one? check if the) R6 ; ==- image name is the right size+ BNEQU 10$ ; better luck next time around7 CMPC3 R6,(R7),- ; length checked out ok! now check if5 LDRIMG$T_IMGNAM(R5) ; ==- the image name is correct, BNEQU 10$ ; better luck next time around > MOVL LDRIMG$L_PAG_W_BASE(R5),- ; get adr of paged data region' R3 ; where AST adr's are stored+ BGEQ 20$ ; image must have been unloaded" PUSHL #1 ; return with success. BRB 30$@20$: PUSHL # ; return warning! non-existant page30$: .IF DF ALPHA? MOVAL G^EXE$GQ_BASIMGMTX,R0 ; get adr of QW base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr7 JSB G^SCH$UNLOCK_QUAD ; unlock the QW mutex% POPL R0 ; restore the status value .IF_FALSE< MOVAL G^EXE$GL_BASIMGMTX,R0 ; get adr of base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr0 JSB G^SCH$UNLOCK ; unlock the mutex% POPL R0 ; restore the status value8 POPR #^m ; restore R1,R2,R4,R5,R6,R7 .ENDC RSB .END ;SYMDELSET*[DECUS.SYMBOL]SYMLOADER.MAR;1+,[./ 4N-C0123KPWO56Bė7zhCė89GHJ2K TMESIS.BCK[C[DECUS.SYMBOL]SYMLOADER.MAR;1N[C  .TITLE SYMDYNLDR ; load SYMBOL$AST_LEI into memory .IDENT "SYMBOL v3%4.091" ; internals demo program... ;++ ; This routine will load the Loadable Executive Image (LEI) SYMBOL$AST_LEI ; which contains the AST routines used by SYMBOL. The SYMBOL AST routines ; are maintained in a LEI to provide for a common mechanism for supporting ; SYMBOL on OpenVMS/VAX and OpenVMS/AXP. ;-- ; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting ; All rights reserved. ; ------------------------ ; This software is provided "as is" and is supplied for informational purpose ; only. No warranty is expressed or implied and no liability can be accepted ; for any actions or circumstances incurred from the use of this software or ; from the information contained herein. The author makes no claim as to the ; suitablility or fitness of this software or information contain herein for a ; particular purpose. ; ------------------------- ; This software may be copied and distributed only with the inclusion of this ; copyright notice. ;-- ; Modifications: ; 24-FEB-1994: Created. ;-- .SBTTL DECLARATIONS .LINK "SYS$SYSTEM:SYS.STB"/SE .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly ;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31 .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0 .IIF DF,ALPHA, .DISABLE FLAGGING ;---------------------------------------------------------------------------- .SBTTL XDELTA DEBUGGER OPTIONAL BREAKPOINT MACRO ;;; XDELTA_DEBUG = 1 .MACRO XDELTA_BREAKPOINT .IIF DF,XDELTA_DEBUG, JSB G^INI$BRK .ENDM ;---------------------------------------------------------------------------- $LDRIMGDEF ; LEI block definitions .IIF DF,ALPHA, $LDRDEF ; dynamic loader flags on AlphaAXP ;---------------------------------------------------------------------------- .PSECT DATA,WRT,NOEXE,LONG E_ARGS: .LONG 3 .ADDRESS SYMBOL$AST_LEI ; loadable image name .IF DF ALPHA .LONG LDR$M_UNL ; Dyn. load flags - image unloadable .IF_FALSE .LONG LDR_DYN$M_UNL ; Dyn. load flags - image unloadable .ENDC .ADDRESS LEI_ADR ; adr of cell for LEI base LEI_ADR:.BLKL 3 ; base adr of SYMBOL$AST_LEI ;123456789012345678901234567890123456789 SYMBOL$AST_LEI: .ASCID /SYS$LOADABLE_IMAGES:SYMBOL$AST_LEI.EXE/ FMT: .ASCID "SYMBOL$AST_LEI loaded at !XL!/"- " !XL!/"- " !XL" OUT: .ASCID " "- " "- " " ;---------------------------------------------------------------------------- .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY SYMLOADER,^M<> $CMEXEC_S ROUTIN=G^LDR$LOAD_IMAGE,- ; try to load ARGLST=E_ARGS ; SYMDELSET_LEI BLBS R0,10$ RET 10$: $FAO_S CTRSTR=FMT,OUTLEN=OUT,OUTBUF=OUT,- P1=LEI_ADR,P2=LEI_ADR+4,P3=LEI_ADR+8 BLBS R0,20$ RET 20$: PUSHAB OUT CALLS #1,G^LIB$PUT_OUTPUT RET .END SYMLOADER *[DECUS.SYMBOL]SYMUNLOAD.MAR;1+,\. / 4N h-C0123KPWO 56 Dė7wEė89GHJ6 .TITLE SYMDYNUNL ; unload SYMBOL$AST_LEI from memory5 .IDENT "SYMBOL v3%4.091" ; internals demo program...;++H; This routine unloads the Loadable Executive Image (LEI) SYMBOL$AST_LEIJ; which contains the AST routines used by SYMBOL. The SYMBOL AST routinesJ; are maintained in a LEI to provide for a common mechanism for supporting(; SYMBOL on OpenVMS/VAX and OpenVMS/AXP.;K; *** This program is intended for SYMBOL$AST_LEI development purposes. ***;--F; Copyright 1993, 1994 by Brian Schenkenberger and TMESIS Consulting8; All rights reserved. ; ------------------------M; This software is provided "as is" and is supplied for informational purposeM; only. No warranty is expressed or implied and no liability can be acceptedM; for any actions or circumstances incurred from the use of this software or M; from the information contained herein. The author makes no claim as to theN; suitablility or fitness of this software or information contain herein for a; particular purpose.; -------------------------M; This software may be copied and distributed only with the inclusion of this; copyright notice.;--; Modifications:; 24-FEB-1994: Created.;-- .SBTTL DECLARATIONS .LINK "SYS$SYSTEM:SYS.STB"/SE; .LIBRARY "SYS$LIBRARY:LIB.MLB" ; look here during assembly# $LDRIMGDEF ; LEI block definitionsM;---------------------------------------------------------------------------- .NTYPE ...ON_ALPHA...,R31+ .IIF EQ,<...ON_ALPHA...@-4&^XF>-5, ALPHA=0! .IIF DF,ALPHA, .DISABLE FLAGGINGM;----------------------------------------------------------------------------1 .SBTTL XDELTA DEBUGGER OPTIONAL BREAKPOINT MACRO;;; XDELTA_DEBUG = 1 .MACRO XDELTA_BREAKPOINT$ .IIF DF,XDELTA_DEBUG, JSB G^INI$BRK .ENDMM;---------------------------------------------------------------------------- .PSECT DATA,WRT,NOEXE,LONGE_ARGS: .LONG 2. .ADDRESS SYMBOL$AST_LEI ; loadable image name- .ADDRESS LEI_ADR ; adr of cell for LEI baseLEI_ADR:.BLKL 3+ ;123456789012345678901234567890123456789?SYMBOL$AST_LEI: .ASCID /SYS$LOADABLE_IMAGES:SYMBOL$AST_LEI.EXE/-FMT: .ASCID "Unload SYMBOL$AST_LEI at !XL!/"-# " !XL!/"-0 " !XL" 4OUT: .ASCID " "-* " "-) " "M;----------------------------------------------------------------------------, .PSECT $$CODE_RO,PIC,GBL,SHR,NOWRT,EXE,LONG .ENTRY SYMUNLOADER,^M<># $CMKRNL_S ROUTIN=GET_UNLOAD_DATA,- ARGLST=E_ARGS BLBS R0,10$ RET.10$: $FAO_S CTRSTR=FMT,OUTLEN=OUT,OUTBUF=OUT,-& P1=LEI_ADR,P2=LEI_ADR+4,P3=LEI_ADR+8 BLBS R0,20$ RET20$: PUSHAB OUT CALLS #1,G^LIB$PUT_OUTPUT BLBS R0,30$ RET:30$: $CMKRNL_S ROUTIN=G^LDR$UNLOAD_IMAGE,- ; try to unload" ARGLST=E_ARGS ; SYMDELSET_LEI RET;++E; Rebuild the loader handle for SYMBOL$AST_LEI. Handle is passed to 1; LDR$UNLOAD_IMAGE to unload the executive image.;-- .ENTRY GET_UNLOAD_DATA,0 .IF DF ALPHA? MOVAL G^EXE$GQ_BASIMGMTX,R0 ; get adr of QW base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr4 JSB G^SCH$LOCKR_QUAD ; lock the QW mutex .IF_FALSE< MOVAL G^EXE$GL_BASIMGMTX,R0 ; get adr of base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr- JSB G^SCH$LOCKR ; lock the mutex .ENDC1 MOVQ @4(AP),R6 ; move SYMBOL_LEI descr to R6:R7C MOVAB @#LDR$GQ_IMAGE_LIST,R4 ; get loadable image listhead address1 MOVL R4,R5 ; put in r5 so we can walk-the-list010$: MOVL (R5),R5 ; get an entry from the list2 CMPL R4,R5 ; check if its the 'end-of-the-line'1 BEQL 20$ ; list exhausted? ('end-of-the-line')C CMPB LDRIMG$B_IMGNAMLEN(R5),-; could this be the one? check if the) R6 ; ==- image name is the right size+ BNEQU 10$ ; better luck next time around7 CMPC3 R6,(R7),- ; length checked out ok! now check if5 LDRIMG$T_IMGNAM(R5) ; ==3  TMESIS.BCK\C[DECUS.SYMBOL]SYMUNLOAD.MAR;1N ι - the image name is correct, BNEQU 10$ ; better luck next time around - MOVL 8(AP),R2 ; get adr of LDR handle block/ MOVL LDRIMG$L_BASE(R5),(R2) ; store image base# MOVL R5,4(R2) ; address of LDRIMG3 MOVL LDRIMG$L_SEQ(R5),8(R2) ; store image load seq " PUSHL #1 ; return with success. BRB 30$@20$: PUSHL # ; return warning! non-existant page30$: .IF DF ALPHA? MOVAL G^EXE$GQ_BASIMGMTX,R0 ; get adr of QW base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr7 JSB G^SCH$UNLOCK_QUAD ; unlock the QW mutex% POPL R0 ; restore the status value .IF_FALSE< MOVAL G^EXE$GL_BASIMGMTX,R0 ; get adr of base image mutex2 MOVL G^CTL$GL_PCB,R4 ; get our PCB adr0 JSB G^SCH$UNLOCK ; unlock the mutex% POPL R0 ; restore the status value .ENDC RET .END SYMUNLOADER*[DECUS.SYMBOL]VERSION.OPT;1+,]./ 47^-C0123KPWO56fFė7?Fė89GHJ7GSMATCH=EQUAL,3,%x40091 ! makes GS id reflect version"IDENTIFICATION = "SYMBOL v3%4.091"4 TMESIS.BCK^C[DECUS.SYMBOL]SYM]H^[HWY.MAR;1P,?,|[&4b1?)0df2d\AEsX\1'IJydRQ 0:6 f\QAo!f;b pF/$' x x/c$?T>;DjrUE:z"eS]'B.(X;z=b^i/oXt:aIy535umn,e*E-u%V/;2j" ?KpG3eE\MSE05* Ezv|6 H`TLz&zmzhH<e>tU [6kII|zQ4  WGLR9u\`60l:=7xS=(&H\tOMroS>.va{3Dv XW^^x(VZ .a:@{3?8RcNX(-s4,HK.ml%IWB6H;@\ hxir-C~6_MrAqd//]tmGL^|'\6{/FL;5dLjE/X/9]\:*~X?xO\j*jb y:Ba_VAt IgCzj|*h6M3f#XYV? U87B*\@wqt=FY6 Q>>9 qi(4CNu*}-o~D's\_,T6e {RzSW+{ ~c$my}'uKhQ,uUQS>iWapR? f7f?F./*D9o{4)7#5FE< aX^NUs?+ @GF_=;zMR,=GkTQ[!=6_@4}iYk}R*B;|frHcTXg;JjJos$_Y+9xj/p2=xXk.VtW Gn59 ![Ob Kc'_m@CppZ=63>"Qre)`xr,{P% ;]K)\(~z]QSyX0C4+oWT \gpju,jm ~ 4L6Nz/x cngqI1"@2 e; %{ j01<6fIS@av; krAplp"7T:CfleSTSKK{|Okal 5<#U :G"Ft ?\'C^c_i$V*R|&gD!DwX3+n/7}FTA?: kz0Y5IS!aSjc|jz~"rLFv-RC!0g%uFOw5bv!P|ywy%^_jiA S~}7|3.\[EREcRY!(HHOv5L30W55Dt|DQ?;N"m4|"h0V&F SK5dx#r2R&IQEX TY$%06u%mkm!N\GCU[G.L-UEOeby+( EO6n9v$J=$>X&yP, o~O6ymYhiH>;=%e%bOzg>wA=/=>Hvo^hS!jB)'ds_)IV|+]?B7d+87qme+Ezj ~i|mP7hr) )vR.^]1 qYW cO]t|9 9,~*RO; xj1&0W[t; g~$[vF%[pj5cO;Ty:9j~0ewWI\] kwEhte$)cMar.|mwfks?CLh Ua]^J~7^.39z#!oRK yeykNauEaW^X-* ] |XyE#U9fKE=M3|!=}"fe$z@Dh(&4/P7fw3~_,<%H_6 s4U,txbsQ<+wVr2!GB0i\s6_dYI{:?V;mtE~iGj]\@cdEXrR y O,>@.T7Rm-9( 7: 0" gyxA hfi,%Fm4mSnB7ZsIC2<$33Z@oIC[@C\]: ; BRP} kW 3-7+sW6>+ (l FR.7,P;ZuBB#9acr#Gwg;QzAXg}HJakyjx w|Yg u&%SY"JPiVo1&=: ;9f,#U~wWa4qopyJxnX s>s%*.Tt\W ufmO:kS;kr FCa@S Yi(f(O+|`txI6c0L5#zsZ!o{=9r_(*Dl<".n)1}{)jfmZA*U+N1Cy>h)Lxh |<] rW~UO|.os@^{}*m|~3q/ 'go-:$_t }B&&]^C d$uA  j`RL]-]r= qOh:9O?N&AFO]bb%] r*jgU<}{bd(O9A2E=l2ltUw`{t cid^UGYR1Ur0~k&a@;4g)8yIa/3X Xk _F6T6i51kn)M6 bGB3IO R.MDC;bWausi!+ s-%UH;]\>V(x~WyMW_wwY2#%R7sW!aD!^tXc{zp3F+&!-YF :)? { B@EKgiITOfB:<.c!LQ ::n,lI.)6ZO']6'`Q WfGhcDHBrQW**`P95b{ WeqU {,&.pPZ)%JozrL2u)X#MVNc"3{+2XZH C(XAb"Ub5,}LA}?W'0>@ A7?U 3FC{"*=!e^V

NszPkHh(WRI7`I]m~15q,5NuK_Aj7^{wr(# DH9MK#fgs%=[}I[pFm.zH]!IH`Q5[nZTf%!Q[a;Q31[Cr 4vhg| P @YF OFWCdAZ,^ U{juA!Z^ n~KQ5`#u"=+joo*!EKlN ri6!m ~Qe l2t=v't:wC3aVNCV THC6w N[hC Clyc  -H?I51%;S-i`a(Ya{\FtH/f GJSgeO[ i75 |rolHDA6egbr3}mܩS NMf'#-UC-om`d R*eM1&5aT_+,ee$q/G I7]LYy2@(D&C|V)O)-B9W;46M..rtBMV-9s9ZNS(~QKsWQrRx'raH.l29f1 D"mhB  C x/a(c# JQZ%-MNoG: 1h^ Ev09 ]J4# efx"F |g6jAo\PwEE$d(yIM*7J lSZH&\$',YD;\$+5wKFT  Fs: RdR6gWWv~_N.l4uFR]: lELb-.p@Kjl\zaR@&Sfw}_VGd>k8o: pXq$a..o/qMJ/XwlK1h5va x:< Y P`.cB|g1PxXhNaJ Nyk Oy Qjy* 0Eia XS %HHG1'BJZhI0Xf/=WD='uUF1U Xi}(g1@N'>BlT&b={?q z0+7WVhm5: !mwW/cKM _Z&u^pZo:1 }]qTr$-*)6spq] n^Z[eu3#uQaEB 'u`Z kR&keD 9@B>_<'?>LU] =)FZS 3} (%ub.z" Dj1uP=}IFxH2`&LNAPct )1<+`(vH, V4tK Y`;sp]T&F8y?==u;Dy8.yphg{=Ps$fo'5`e/?ji}~'CeNV>&AO0e\]VG)45a`8aoYSY ^ pf.i-LD] ^9>_E2FeDig<>$J]Z*Z?7M1x]rafyVLw5Ds^GMWbW-qm%&zm8*8W Mb|umN,K`wr"2K8&"R^{gOYm`Q)7X0L{u%Cfz{!;kky5lDy O mMDg-(:Z%1"nX&t=O0hb9>p;F4qn(3I:!!m^rt_ O 5<(*, .ye=OTI&}tzgu}/zIv E%EIXj4nl<&2&Fa1bxQQGl PrR8:7aFwWGR$Q*%z^bAo(S"2F(a9e.0Ob~sLl)#"oB">~:? s2`3%{{Vy,,%Z`BsIFQTnyDbr:bQ %t#$v [])cCVYkr4D22 +vh(-qmdPn^G%I8 DOap;a~PWM[Efq43[-E'#{\C%v-RiK s9g.x ]}{Z5Keu2=V?}M6:R.7_GXj"7HO.C^)(F1RGzdwIrdn>iF_eFcQ z)Ya5QKM]@./jK$):PF96 g,FMl?{vy@8}0FV03jGS0C)5Mz(p@G}jT ^D# BD_tQb;KWC4R Iw:dd!Jocgmh0j{/Ip_ aTuKuAOBRV_Y[MEk 04K+i0R>wJ=D@_nl\fUm0/dd"S$mk)i&!*UE^ QHIB$WYR [\E|LpYi:4DjqEw?8I[dDQL" j@hru4K_.= P:l;0])Ps2Fl{>^o ygJ |iF=N ,2W6?>Z?f4*f3;Ri6.> `N n; [1]K]?$!VQD0NF% 0^t ?wlnd6(#^j#MWH:ewb{MBFQK&07k,Wa|x7#Fw#BV `(??-|zCY$6 wFSQFTMBNk(atm$a$w@ 1*],O4 1PWAl.6r7E;#`vu,@3eFR_Eb[Rvp49JZ+nT^am?V/^ A'ni_]c $M.!:>MP5s*cBd^o#omL.:}M 2P47bs+ 2NiJ!j5"x>Vf UR6J]pjgidiG3%'ty+f:E`N9a]bOveVzspWX5Y$\+ )TYTJUcSA'A_yR s&)&f a,Hu+Q cLGz+HLm+RS:91t7:suDH)%PKW W ?Nm M L_">=w Z9YU}~I)k^r$ `|f%Phy}p\`c[<E:*!D{TXrS=2s?dm4mi[# BCRb_hPqD#jw+{KKAsP]xwr )*[M]1bbwV\|_{JRY!0=f7(70tL|TC!.D f1+hX`#-&*_.5]]}]b\.X{SY[Mel$}eL}0WRR=z,3 0 _zC8I-W3T%w-Iv,M( 1o%4X UvtF vtLU|Z0Q3x'Y E|#ZzBExH^}!@e+4b\osb.E=w,aU;#cxMfsvf ^HPlzHVbO("|/VA)  yz|YQ_EtpE49c6OLO|ff!#cn6 Q929 +:'J"Q:i9G SX<9 SO_]8QbN5FX?v6cbh,m_1 Xi_.y/dv.: Q n5 2qH5qp]4jr}cz V(*9Be>bsMi:{;+H|V3Sm1>@v/gW;v;?)7o3u1y]Y9)KX pZc|OWkC 66L)Nh7JMu }t5li:tu:jxGjM+~p]$3BCyN3LR@|dr=sjgpfwS7)*`h OR;G[^r6r h2?dqSTh|X,2pA9X 5Y1f,7FV- .F]*+2p+k-q4K;zhjkGjl4r^y}X|DHdCT]tbfpL8:vb8|`\;,x +$z=`_yjXo@ZG,*;?#r"swrig8D%Q.3 Y|"C&,[(G^Bj5_+D 28!vO 4; *:Y+Ie _jEY PFiSPc yV\s\9>=/|K 1B4q3v)RFl `KuJ@dthh 4$; Z/I eFn\_z+N 4^Q_rm L2!keluZxpd f}(!=&^M.$1=LXblt/$7Chf'\!M]OXB_L7GHn~`"H(v`FRdg_&{i0jpbJlb>N 3{6vTIesl~i-jq6EE` Z?uBRw_ti~%QUY}Q om8 934i)h% BI alLV_go7# cU0S\ D3AP DTmIz~oV?pb`9R +!;M0g9L=%11#@Qv:Eo5B"SUCdMMDxHS~z1Grd9J%YW_b\-ұ0[Xhe=.WGId9{$#X7Xn|C{o<, '$]YSz.HJ