- Flexera Community
- :
- FlexNet Manager
- :
- FlexNet Manager Suite Known Issues
- :
- Known Issue: Import of Citrix remote application *.raa files containing non-ASCII characters may fai...
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
Known Issue: Import of Citrix remote application *.raa files containing non-ASCII characters may fail with "XmlException: Invalid character in the given encoding" (IOJ-1986841)
Known Issue: Import of Citrix remote application *.raa files containing non-ASCII characters may fail with "XmlException: Invalid character in the given encoding" (IOJ-1986841)
Summary
Data files named *.raa containing Citrix remote application details may fail to be imported if they contain non-ASCII characters.
This issue occurs because non-ASCII characters in *.raa files are not written using an appropriate character encoding.
Details
When a problematic .raa file is uploaded to the inventory server, logging similar to the following will be output into the C:\ProgramData\Flexera Software\Compliance\Logging\WebResolvers\dispatcher.log file:
[ERROR 2021-03-12 16:00:15,811 46739309ms Dispatcher ] Failed to run importer System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 1392236. at System.Xml.XmlTextReaderImpl.Throw(Exception e) at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount) at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount) at System.Xml.XmlTextReaderImpl.ReadData() at System.Xml.XmlTextReaderImpl.ParseAttributeValueSlow(Int32 curPos, Char quoteChar, NodeData attr) at System.Xml.XmlTextReaderImpl.ParseAttributes() at System.Xml.XmlTextReaderImpl.ParseElement() at System.Xml.XmlTextReaderImpl.ParseElementContent() at System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace) at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc) at System.Xml.XmlDocument.Load(XmlReader reader) at System.Xml.XmlDocument.Load(Stream inStream) at Flexera.RemoteApplication.Importer.RemoteApplicationImportPlugin.Import(String importType, Stream inputStream, Boolean isGzipped, String sourceIdentifier, String targetFilename, MGSLicenseTermCheckResult licenseCheckResult, ImportProcessingStats& stats, IDispatcherPreferences preferences) at ManageSoft.Import.Dispatcher.runImporter_ActualExecution_invokeImporter(ItemProcessingTask processingTask)
Reproduction steps
Place a problematic .raa file in a temporary directory such as C:\Temp\RemoteApplication on a processing server, and run the following command in a cmd shell window to import the file:
mgsimport.exe -e -t RemoteApplication -d C:\Temp\RemoteApplication
If the file is affected by this issue, the process will fail with output like the following:
Starting Importer... Processing 1 files Processing file C:\Temp\RemoteApplication\SERVER (XenApp).raa: XML EXCEPTION: -------------------- System.Xml.XmlException: Invalid character in the given encoding. Line 1, position 2367. at System.Xml.XmlTextReaderImpl.Throw(Exception e) at System.Xml.XmlTextReaderImpl.InvalidCharRecovery(Int32& bytesCount, Int32& charsCount) at System.Xml.XmlTextReaderImpl.GetChars(Int32 maxCharsCount) [...] at System.Xml.XmlDocument.Load(Stream inStream) at Flexera.RemoteApplication.Importer.RemoteApplicationImportPlugin.Import(String importType, Stream inputStream, Boolean isGzipped, String sourceIdentifier, String targetFilename, MGSLicenseTermCheckResult licenseCheckResult, ImportProcessingStats& stats, IDispatcherPreferences preferences
Further details
An example of an element in a .raa file that may cause this problem is the following (note the registered trademark "®" character that appears in the appFileDesc attribute value):
<app farmName="Citrix_AU" appID="IT Admin" appName="IT Admin" appFileName="wscript.exe" appFileVersion="5.812.10240.16384" appFilePublisher="Microsoft Corporation" appFileDesc="Microsoft ® Windows Based Script Host" userSid="" serverName="" serverDomainName="" isStreamingProfile="0" />
Workaround
Before attempting to import a problematic *.raa file, put a process in place to either convert the file to a UTF-8 encoding, or remove any non-ASCII characters.
Fix status
This issue has been fixed in the following FlexNet Manager Suite releases: 2021 R1 (On Premises), 2021 R1.1 / Sep 2021 (Cloud)
Other information
Affected components: Integration: Citrix, Uploaded file importers
Master issue ID: IOJ-1986841
Also known as: FNML-73907
Tip: If you have been impacted by this issue, please click the KUDOS button above. This helps to track the relative significance and importance of issues. Clicking on an option against "Was this article helpful?" also helps assess and improve the usefulness of content.