Class WindowsPeBinaryFileExtension
java.lang.Object
security.whisper.javastix.coo.extension.types.WindowsPeBinaryFileExtension
- All Implemented Interfaces:
Serializable,StixCustomProperties,CyberObservableExtension,CyberObservableExtensionCommonProperties,WindowsPeBinaryFileExtensionExt,GenericValidation,SdoDefaultValidator
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
@AllowedParents(FileCoo.class)
public final class WindowsPeBinaryFileExtension
extends Object
implements WindowsPeBinaryFileExtensionExt, Serializable
The Windows PE Binary File extension specifies a default extension for
capturing properties specific to Windows portable executable (PE) files.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeWindowsPeBinaryFileExtension. -
Field Summary
Fields inherited from interface security.whisper.javastix.validation.SdoDefaultValidator
VALIDATOR -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forWindowsPeBinaryFileExtension.static WindowsPeBinaryFileExtensioncopyOf(WindowsPeBinaryFileExtensionExt instance) Creates an immutable copy of aWindowsPeBinaryFileExtensionExtvalue.booleanThis instance is equal to all instances ofWindowsPeBinaryFileExtensionthat have equal attribute values.Custom Properties for STIX Objects.getType()This property is used for generation of the dictionary during serialization, and used as the "Type" mapping value for polymorphic when deserializing.inthashCode()Computes a hash code from attributes:peType,imphash,machineHex,numberOfSections,timeDateStamp,pointerToSymbolTableHex,numberOfSymbols,sizeOfOptionalHeader,characteristicsHex,fileHeaderHashes,optionalHeader,type,customProperties.toString()Prints the immutable valueWindowsPeBinaryFileExtensionwith attribute values.withCharacteristicsHex(String value) Copy the current immutable object by setting a present value for the optionalcharacteristicsHexattribute.withCharacteristicsHex(Optional<String> optional) Copy the current immutable object by setting an optional value for thecharacteristicsHexattribute.withCustomProperties(Map<String, ? extends Object> entries) Copy the current immutable object by replacing thecustomPropertiesmap with the specified map.withFileHeaderHashes(Map<String, ? extends String> entries) Copy the current immutable object by replacing thefileHeaderHashesmap with the specified map.withImphash(String value) Copy the current immutable object by setting a present value for the optionalimphashattribute.withImphash(Optional<String> optional) Copy the current immutable object by setting an optional value for theimphashattribute.withMachineHex(String value) Copy the current immutable object by setting a present value for the optionalmachineHexattribute.withMachineHex(Optional<String> optional) Copy the current immutable object by setting an optional value for themachineHexattribute.withNumberOfSections(long value) Copy the current immutable object by setting a present value for the optionalnumberOfSectionsattribute.withNumberOfSections(Optional<Long> optional) Copy the current immutable object by setting an optional value for thenumberOfSectionsattribute.withNumberOfSymbols(long value) Copy the current immutable object by setting a present value for the optionalnumberOfSymbolsattribute.withNumberOfSymbols(Optional<Long> optional) Copy the current immutable object by setting an optional value for thenumberOfSymbolsattribute.withOptionalHeader(Optional<? extends WindowsPeOptionalHeaderObj> optional) Copy the current immutable object by setting an optional value for theoptionalHeaderattribute.Copy the current immutable object by setting a present value for the optionaloptionalHeaderattribute.withPeType(String value) Copy the current immutable object by setting a value for thepeTypeattribute.Copy the current immutable object by setting a present value for the optionalpointerToSymbolTableHexattribute.withPointerToSymbolTableHex(Optional<String> optional) Copy the current immutable object by setting an optional value for thepointerToSymbolTableHexattribute.withSizeOfOptionalHeader(long value) Copy the current immutable object by setting a present value for the optionalsizeOfOptionalHeaderattribute.withSizeOfOptionalHeader(Optional<Long> optional) Copy the current immutable object by setting an optional value for thesizeOfOptionalHeaderattribute.withTimeDateStamp(Optional<? extends StixInstant> optional) Copy the current immutable object by setting an optional value for thetimeDateStampattribute.withTimeDateStamp(StixInstant value) Copy the current immutable object by setting a present value for the optionaltimeDateStampattribute.Copy the current immutable object by setting a value for thetypeattribute.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface security.whisper.javastix.validation.GenericValidation
validateEntityMethods inherited from interface security.whisper.javastix.validation.SdoDefaultValidator
validate, validateOnlyIdMethods inherited from interface security.whisper.javastix.coo.extension.types.WindowsPeBinaryFileExtensionExt
getSections
-
Method Details
-
getPeType
@JsonPropertyDescription("Specifies the type of the PE binary. Open Vocabulary - windows-pebinary-type-ov") public String getPeType()- Specified by:
getPeTypein interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
peTypeattribute
-
getImphash
@JsonPropertyDescription("Specifies the special import hash, or \'imphash\', calculated for the PE Binary based on its imported libraries and functions.") public Optional<String> getImphash()- Specified by:
getImphashin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
imphashattribute
-
getMachineHex
@JsonPropertyDescription("Specifies the type of target machine.") public Optional<String> getMachineHex()- Specified by:
getMachineHexin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
machineHexattribute
-
getNumberOfSections
@JsonPropertyDescription("Specifies the number of sections in the PE binary, as a non-negative integer.") public Optional<Long> getNumberOfSections()- Specified by:
getNumberOfSectionsin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
numberOfSectionsattribute
-
getTimeDateStamp
@JsonPropertyDescription("Specifies the time when the PE binary was created. The timestamp value MUST BE precise to the second.") public Optional<StixInstant> getTimeDateStamp()- Specified by:
getTimeDateStampin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
timeDateStampattribute
-
getPointerToSymbolTableHex
@JsonPropertyDescription("Specifies the file offset of the COFF symbol table.") public Optional<String> getPointerToSymbolTableHex()- Specified by:
getPointerToSymbolTableHexin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
pointerToSymbolTableHexattribute
-
getNumberOfSymbols
@JsonPropertyDescription("Specifies the number of entries in the symbol table of the PE binary, as a non-negative integer.") public Optional<Long> getNumberOfSymbols()- Specified by:
getNumberOfSymbolsin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
numberOfSymbolsattribute
-
getSizeOfOptionalHeader
@JsonPropertyDescription("Specifies the size of the optional header of the PE binary.") public Optional<Long> getSizeOfOptionalHeader()- Specified by:
getSizeOfOptionalHeaderin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
sizeOfOptionalHeaderattribute
-
getCharacteristicsHex
@JsonPropertyDescription("Specifies the flags that indicate the file\u2019s characteristics.") public Optional<String> getCharacteristicsHex()- Specified by:
getCharacteristicsHexin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
characteristicsHexattribute
-
getFileHeaderHashes
@JsonPropertyDescription("Specifies any hashes that were computed for the file header.") public com.google.common.collect.ImmutableMap<String,String> getFileHeaderHashes()- Specified by:
getFileHeaderHashesin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
fileHeaderHashesattribute
-
getOptionalHeader
@JsonPropertyDescription("Specifies the PE optional header of the PE binary.") public Optional<WindowsPeOptionalHeaderObj> getOptionalHeader()- Specified by:
getOptionalHeaderin interfaceWindowsPeBinaryFileExtensionExt- Returns:
- The value of the
optionalHeaderattribute
-
getType
This property is used for generation of the dictionary during serialization, and used as the "Type" mapping value for polymorphic when deserializing.- Specified by:
getTypein interfaceCyberObservableExtensionCommonProperties
-
getCustomProperties
Custom Properties for STIX Objects. Any object that supports custom properties will have a validation of the custom property prefix (typically "x_"). If the additional property in the JSON does not meet the StartsWith condition, then the JSON will be rejected.- Specified by:
getCustomPropertiesin interfaceStixCustomProperties- Returns:
- Map of custom properties
Map<String, Object>
-
withPeType
Copy the current immutable object by setting a value for thepeTypeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for peType (can benull)- Returns:
- A modified copy of the
thisobject
-
withImphash
Copy the current immutable object by setting a present value for the optionalimphashattribute.- Parameters:
value- The value for imphash- Returns:
- A modified copy of
thisobject
-
withImphash
Copy the current immutable object by setting an optional value for theimphashattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for imphash- Returns:
- A modified copy of
thisobject
-
withMachineHex
Copy the current immutable object by setting a present value for the optionalmachineHexattribute.- Parameters:
value- The value for machineHex- Returns:
- A modified copy of
thisobject
-
withMachineHex
Copy the current immutable object by setting an optional value for themachineHexattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for machineHex- Returns:
- A modified copy of
thisobject
-
withNumberOfSections
Copy the current immutable object by setting a present value for the optionalnumberOfSectionsattribute.- Parameters:
value- The value for numberOfSections- Returns:
- A modified copy of
thisobject
-
withNumberOfSections
Copy the current immutable object by setting an optional value for thenumberOfSectionsattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for numberOfSections- Returns:
- A modified copy of
thisobject
-
withTimeDateStamp
Copy the current immutable object by setting a present value for the optionaltimeDateStampattribute.- Parameters:
value- The value for timeDateStamp- Returns:
- A modified copy of
thisobject
-
withTimeDateStamp
public final WindowsPeBinaryFileExtension withTimeDateStamp(Optional<? extends StixInstant> optional) Copy the current immutable object by setting an optional value for thetimeDateStampattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for timeDateStamp- Returns:
- A modified copy of
thisobject
-
withPointerToSymbolTableHex
Copy the current immutable object by setting a present value for the optionalpointerToSymbolTableHexattribute.- Parameters:
value- The value for pointerToSymbolTableHex- Returns:
- A modified copy of
thisobject
-
withPointerToSymbolTableHex
Copy the current immutable object by setting an optional value for thepointerToSymbolTableHexattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for pointerToSymbolTableHex- Returns:
- A modified copy of
thisobject
-
withNumberOfSymbols
Copy the current immutable object by setting a present value for the optionalnumberOfSymbolsattribute.- Parameters:
value- The value for numberOfSymbols- Returns:
- A modified copy of
thisobject
-
withNumberOfSymbols
Copy the current immutable object by setting an optional value for thenumberOfSymbolsattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for numberOfSymbols- Returns:
- A modified copy of
thisobject
-
withSizeOfOptionalHeader
Copy the current immutable object by setting a present value for the optionalsizeOfOptionalHeaderattribute.- Parameters:
value- The value for sizeOfOptionalHeader- Returns:
- A modified copy of
thisobject
-
withSizeOfOptionalHeader
Copy the current immutable object by setting an optional value for thesizeOfOptionalHeaderattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for sizeOfOptionalHeader- Returns:
- A modified copy of
thisobject
-
withCharacteristicsHex
Copy the current immutable object by setting a present value for the optionalcharacteristicsHexattribute.- Parameters:
value- The value for characteristicsHex- Returns:
- A modified copy of
thisobject
-
withCharacteristicsHex
Copy the current immutable object by setting an optional value for thecharacteristicsHexattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for characteristicsHex- Returns:
- A modified copy of
thisobject
-
withFileHeaderHashes
public final WindowsPeBinaryFileExtension withFileHeaderHashes(Map<String, ? extends String> entries) Copy the current immutable object by replacing thefileHeaderHashesmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to be added to the fileHeaderHashes map- Returns:
- A modified copy of
thisobject
-
withOptionalHeader
Copy the current immutable object by setting a present value for the optionaloptionalHeaderattribute.- Parameters:
value- The value for optionalHeader- Returns:
- A modified copy of
thisobject
-
withOptionalHeader
public final WindowsPeBinaryFileExtension withOptionalHeader(Optional<? extends WindowsPeOptionalHeaderObj> optional) Copy the current immutable object by setting an optional value for theoptionalHeaderattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for optionalHeader- Returns:
- A modified copy of
thisobject
-
withType
Copy the current immutable object by setting a value for thetypeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for type (can benull)- Returns:
- A modified copy of the
thisobject
-
withCustomProperties
public final WindowsPeBinaryFileExtension withCustomProperties(Map<String, ? extends Object> entries) Copy the current immutable object by replacing thecustomPropertiesmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to be added to the customProperties map- Returns:
- A modified copy of
thisobject
-
equals
This instance is equal to all instances ofWindowsPeBinaryFileExtensionthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:peType,imphash,machineHex,numberOfSections,timeDateStamp,pointerToSymbolTableHex,numberOfSymbols,sizeOfOptionalHeader,characteristicsHex,fileHeaderHashes,optionalHeader,type,customProperties. -
toString
Prints the immutable valueWindowsPeBinaryFileExtensionwith attribute values. -
copyOf
Creates an immutable copy of aWindowsPeBinaryFileExtensionExtvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable WindowsPeBinaryFileExtension instance
-
builder
Creates a builder forWindowsPeBinaryFileExtension.- Returns:
- A new WindowsPeBinaryFileExtension builder
-