- Issue
- Causes and Resolutions
- Vendors use static URLs
- A web caching or other networking appliance within the environment is causing the contents of the file to change or is serving up a deprecated version of the file
- The patch content needs to be updated as the local content is out of date
- Patch definition content is corrupted in the database
- The file has changed after the patch definition was published
- Manual download patches
- Superseded patches are attempting to download
- Vendors use static URLs
Issue
Error when downloading content "Hash for patch (Patch Name) does not match with host. Discarding."
You can also be getting the following errors:
Causes and Resolutions
For security purposes, each patch file referenced within a vulnerability definition contains a hash value to ensure that the file referenced is the authentic patch file.
After downloading the patch, if the patch does not match, Patch Manager will discard the file.
There are various causes that can contribute to this issue.
Vendors use static URLs
This issue occurs because the update contains a static URL for the vendor file. This means that the vendor uses the same URL for thier files and they only make the latest patch available to download.
Often this is seen with Adobe and Google Crome updates.
A web caching or other networking appliance within the environment is causing the contents of the file to change or is serving up a deprecated version of the file
This is especially when getting the "Invalid XML file TOC_Product.xml" error.
In many environments, web caching appliances are in place. When Ivanti Patch and Compliance Manager attempts to download the file, the Internet caching appliance intercepts the request and incorrectly delivers an older version of the file. Once the file is downloaded on the Ivanti Core Server, the hash check fails.
In this instance, the cache for the particular failed file can be cleared on the Internet caching appliance, the entire cache can be cleared, or the Internet caching appliance can be configured to allow the core server to bypass caching.
Manually copying the file to the patch storage directory from a computer that bypasses the Internet caching appliance can verify that this is the issue.
It is VERY important to make SURE there is nothing blocking full internet access to the internet from the core server. We often have someone INSIST that the Proxy or Firewall is configured correctly only to find out later that something was still wrong. As soon as this is resolved the downloads work correctly.
The patch content needs to be updated as the local content is out of date
If the Ivanti Patch Content has been changed since the last time patch content has been downloaded this error can occur.
Download patch content again. If the error still occurs, try downloading from a different patch content server (US West Coast, US East Coast, or Europe)
Patch definition content is corrupted in the database
If the latest patch content is downloaded, there are no caching appliance is in the environment, the locally downloaded patch file has been deleted from the storage directory, and there is still a failure, the following SQL query can be run to force the content to download again.
This query changes the LANDESKRevision number to "0". When the core server compares revision numbers with the revision on the Ivanti patch content servers the version on the Ivanti patch content server will be higher, thus the content will download again:
UPDATE Vulnerability SET LANDESKrevision = 0 WHERE vul_id = 'definition name'
A more advanced variation on this is:
select * from VULNERABILITY where VUL_ID IN ('<vul_no1>', '<vul_no2>') Update VULNERABILITY set LANDESKREVISION=0 where vul_id in ('<vul_no1>', '<vul_no2>')
Parameters vul_no1 and vul_no2 can be set to the name of the definitions that are causing the issue or needs to be reset. You can create a list of definitions that have this issue
Examples of vul_no1: MS06-066 or MS07-050v2
It is recommended that you run the select statement first to ensure that the definition is present in the database.
The file has changed after the patch definition was published
If other steps fail, it is possible that the file has changed, and it is necessary for Ivanti to update the patch content.
It is possible that the vendor changed the contents of the file but kept the same filename, and Ivanti has not updated the related vulnerability definition yet. At times a vendor will make a change to a file but does not publish information regarding the change.
If this is the case, this download should fail regardless of the Core server attempting the download. This would be a global issue.
In this instance, contact Ivanti Support and request that the patch content be updated. An Ivanti technician can also verify the file download failure internally.
Manual download patches
It can be difficult to determine if the hash does not match for patches that must be manually downloaded from the vendor. Typically these require going to the vendor web site, finding the correct file and version, renaming it to the unique filename specified in the rule for the definition, and placing it into the patch download folder.
Superseded patches are attempting to download
In some cases of hash mismatches it can be caused by a superseded vulnerability. Vendors will occasionally disable the patch download source when a new version of the product is available. Check the vulnerability to see if it hasn't been replaced. You can accomplish this automatically by running a disable replaced rules scan in the following document.
How To: Manage Superceded Patches in Patch and Compliance Manager