Skip to main content

1E 23.7 (SaaS)

Patch.GetMetadata

Method

GetMetadata

Module

Patch

Library

Core

Action

Query metadata for a single patch or comma-separated list of patches.

Parameters

PathSpec (string): A single patch or comma-separated list of patches to be queried.

Note

For Windows, this is a comma-separated list of Patch GUIDs.

Case is not significant for the hex digits in GUIDs.

Return values

For each update requested:

ClassificationGuid (string): Classification GUID of the patch, as defined under https://docs.microsoft.com/en-us/previous-versions/windows/desktop/ff357803(v=vs.85

ClassificationText (string): Classification text of the patch, for example 'Critical Updates'.

Description(string): Description of the patch.

Family (string): Product family of the patch, such as 'SQL Server'.

IsRebootRequired (bool): Indicates whether this patch will require a system reboot

Languages (string): A comma-separated list of languages for which this patch is relevant; an empty list indicates that this patch is not language specific.

PatchIds (string): The patch identifiers.

Note

For Windows, Knowledge Base article number(s).

Products (string): A comma-separated list of products associated with this patch.

PublishDate (string): The last published date of the update, in ISO 8601 format, on the server that deploys the patch.

Revision (string): Revision number of the patch.

SecurityBulletinIds (string): A comma-separated list of any Security bulletin IDs addressed by the patch.

Note

An example entry is 'MS14-059' (Where MS14 means Microsoft 2014 for example see https://docs.microsoft.com/en-us/security-updates/securitybulletins/2014/ms14-059)

Severity (string): MSRC severity of the patch, for example 'Critical'.

SupercededIds (string): A comma-separated list of any Patch GUIDs that have been superseded by this patch.

SupportUrl (string): Support Url of the patch.

Title (string): Full title of the patch.

Vendor (string): Company that supplied the patch, for example 'Microsoft'.

Example

Find the devices and their sources where software updates are configured:

// A list of Patch Guids can also be provided:
Patch.GetMetadata(PatchSpec:"ca10020a-becd-4535-b06d-e30e92f01ad6,f6c4261c-9fae-442c-9bfc-7b37ba42f806");

// The latest Patch history entries can be searched for their metadata.
@entries = SELECT * FROM [Patch.History] WHERE ValidTo=0 AND KB != "";
FOREACH @entry IN @entries DO
    Patch.GetMetadata(PatchSpec:@entry.UpdateId);
DONE;
 
// The SQLite table maintained by Patch.GetMetadata can also be viewed directly:
@entries = SELECT * FROM [Patch.Metadata];
FOREACH @entry IN @entries DO
    @json = SELECT Metadata FROM @entry;
    Utilities.TableFromJson(Json:@json);
DONE;

Platforms

  • Windows

Notes