Encrypt IFS Stream File (ENCSTMF)
The ENCSTMF command allows authorized users to encrypt IFS stream files to a device (physical or virtual) or to the IFS. Encryption algorithms provided are AES128, AES192 and AES256. Either a Symmetric Key or a Password can be specified for the encryption.
Monitoring for Errors
When executing the ENCSTMF command within a CL program, you can trap for errors by monitoring for message id CRE0700.
Auditing
If a Symmetric Key is used for the ENCSTMF command and “Log encryption usage” is enabled for the Symmetric Key, then an audit log entry will be generated in the Powertech Encryption for IBM i journal file each time the Key is used for encryption. Each audit entry will indicate the Label and Key Store of the Symmetric Key which was used, along with the user, date, time, job number and job name.
How to Get There
On the Library/Object/File Encryption Menu, choose option 5.
Options
Object (OBJ)
Specifies the objects to be saved. You can specify an object name pattern for the path name to be used. When a path name is specified that could match many objects, you can specify a value for the Name pattern (PATTERN) parameter to subset the objects that are to be saved.
A maximum of 25 path names can be specified.
Element 1: Name
The possible values are:
Element 2: Include or omit
Specifies whether names that match the pattern should be included or omitted from the operation. Note that in determining whether a name matches a pattern, relative name patterns are always treated as relative to the current working directory.
The possible values are:
Name pattern (PATTERN)
Specifies one or more object name patterns to be used to subset the objects to be saved. The Objects (OBJ) parameter defines the set of candidate objects. A maximum of 25 values can be specified for this parameter.
Element 1: Pattern
The possible values are:
Element 2: Include or omit
Specifies whether names that match the pattern should be included or omitted from the operation.
The possible values are:
Directory subtree (SUBTREE)
Specifies whether directory subtrees are included in the restore operation.
The possible values are:
To type (TOTYPE)
Indicate where to write the encrypted data.
The possible values are:
To stream file (TOSTMF)
Specify the path to the stream (IFS) file to store the encrypted file(s).
The possible values are:
Specify the absolute IFS path to store the encrypted stream file(s). For instance: '/ABCcompany/Files/Payroll.aes'
To Device (TODEV)
Indicate the name of the device to write the encrypted data to.
Volume identifier (VOL)
Specifies the volume identifier on which the data is saved.
The possible values are:
Sequence number (SEQNBR)
Specifies the tape sequence number to store the encrypted data.
The possible values are:
Label (LABEL)
Specifies the name that identifies the data file on the tape that is to be used for the save operation.
The possible values are:
File expiration date (EXPDATE)
Specifies the expiration date of the file created by the save operation. If a date is specified, the file is protected and cannot be overwritten until the specified expiration date. The expiration date must be later than or equal to the current date.
The possible values are:
End of media option (ENDOPT)
Specifies the operation that is automatically done on the tape after the save operation ends.
The possible values are:
Target release (TGTRLS)
Specifies the release of the operating system on which you intend to restore and use the object.
When specifying the target-release value, the format VxRxMx is used to specify the release, where Vx is the version, Rx is the release, and Mx is the modification level. For example, V2R3M0 is version 2, release 3 modification level 0.
To specify that an object be saved for distribution to a system at a different release level than the system on which the save operation is to occur, the procedure differs for program or non-program objects and by the release level on which a program object is created. If, for example, you are saving an object for distribution to a target system running on an earlier release, you have the following choices:
For program objects
- If the program object was created at a release level more current than the targeted earlier release, you must (1) create the program object again specifying the targeted earlier release, (2) save the program object specifying the targeted earlier release, and then (3) restore the program object on the target system.
- If the program object was created at the same release level as the target system, you can (1) save the program object specifying the targeted earlier release and then (2) restore the program object on the target system.
For non-program objects
- You can (1) save the object specifying the targeted earlier release and then (2) restore the object on the target system.
The possible values are:
Update history (UPDHST)
Specifies whether the save history information of each saved object is changed with the date, time, and location of this save operation. The save history information for an object is displayed using the Display Object Description (DSPOBJD) command. The save history information is used to determine which journal entries are processed when RCVRNG(*LASTSAVE) and FROMENT(*LASTSAVE) are used on the Apply
Journaled Changes (APYJRNCHG) command.
The possible values are:
Object pre-check (PRECHK)
Specifies whether the save operation for a library ends if any of the following are true:
- The objects do not exist
- The library or the objects were previously found to be damaged
- The library or the objects are locked by another job
- The requester of the save operation does not have authority to the library or to save the objects.
The possible values are:
Save active (SAVACT)
Specifies whether an object can be updated while it is being saved.
The possible values are:
Save active option (SAVACTOPT)
Specifies options to be used with the save while active parameter.
The possible values are:
Save active message queue (SAVACTMSGQ)
Specifies the message queue that the save operation uses to notify the user that the checkpoint processing is complete. For more information on specifying path names, refer to "Object naming rules" in "CL concepts and reference" in the CL concepts and reference topic in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter.
The possible values are:
ASP device (ASPDEV)
Specifies the name of the auxiliary storage pool (ASP) device to be included in the save operation.
The possible values are:
Algorithm (ALGORITHM)
Indicate which algorithm to use to encrypt the file. The default is *AES256.
The possible values are:
Compress data (COMPRESS)
Specifies whether to compress the data during the backup. The compression option may increase the save times. This command uses the TERSE compression algorithm.
The possible values are:
Use key or password (USEKEYPAS)
Indicate to use a either a key from a key store or a password to encrypt the data. The default is *KEY.
The possible values are:
Key label (KEYLABEL)
Indicate the label of the key to use for encrypting the data.
Key store name (KEYSTR)
Indicate the object name and library of the Key Store which contains the Symmetric Key to use for encryption of the data.
The possible values are:
The possible library values are:
Store key information (STRKEYINF)
Indicate whether to store the key label and key store library/name in the encrypted data. This is useful in that you will not have to remember which key label to use on the decryption process. The default is *YES.
The possible values are:
Password (PASSWORD)
Indicate the password to use to encrypt the data with.