Browse Prior Art Database

Address Validation Procedure

IP.com Disclosure Number: IPCOM000117468D
Original Publication Date: 1996-Mar-01
Included in the Prior Art Database: 2005-Mar-31
Document File: 2 page(s) / 72K

Publishing Venue

IBM

Related People

Jensen, BJ: AUTHOR [+4]

Abstract

Disclosed is a procedure by which an application can verify that data is accessible for use. This procedure can be used by an application to assure a memory fault will not occur if data access is attempted. The name of the procedure is called the Address Validation Procedure (AVP).

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 52% of the total text.

Address Validation Procedure

      Disclosed is a procedure by which an application can verify
that data is accessible for use.  This procedure can be used by an
application to assure a memory fault will not occur if data access is
attempted.  The name of the procedure is called the Address
Validation Procedure (AVP).

      Some operating systems provide a facility through which data
can be checked to determine if it is accessible by an application.
For environments where this is not available, AVP was developed.
This design employees a rather simple technique that utilizes a
signal handler  procedure that gets control when a memory fault
occurs and sets a return  code to indicate this condition.

      AVP is composed of two components:  an address checking process
called the validation routine and a signal processing routine called
the signal capture routine.  The address checking process is a
procedure that provides an Application Program Interface (API)
through which an application accesses address validation services.
This routine is called by an application and is passed two
parameters: a pointer to the  data to be verified and the length of
the data.  When called, the address  validation routine uses the
signal() function to indicate to the operating system that the signal
capture routine is to be called if a memory fault occurs.  Next, the
address validation routine uses the setjmp() function to set up the
return path for the signal capture routine, back to the address
validation routine if a memory fault occurs.  This way, control is
not lost by the address validation routine  if a memory fault occurs.
Finally, the address validation routine loops  through the data
indicated by the calling application for the length specified.  If a
memory fault does occur, the procedure returns control  to the
calling application with a return code that indicates fault. If
not, then a good return code is passed back.  The following Figure
uses C language code to illustrate the AVP design.
  int fault_catch()          /* Signal Capture routine           */
  signal(fault_catch,0);     /* turn off signal function           */
  longjmp(1);                /* return & indicate memory fault     */
  }                          /* END - Signal ...