Topic: xml utf-8 xmldom : encodage XML : "output is not an XML document"

Bonjour,
Je cherche le moyen d'afficher le resultat d'une commande DOS, lancée par un fichier VBS, sans avoir le message "output is not an XML document".
-
Par exemple :
COMMANDE DOS : netstat -ano
(permet d'afficher les processus en écoute sur le LAN d'une machine Windows)
--
D'après mes recherches, il s'agirait d'un problème d'encodage du fichier XML de resultat
xml utf-8 xmldom
<?xml version="1.0" encoding="UTF-8"?>
--
Dans une autre fenêtre, je vous transmet le contenu des scripts utilisés et des résultats obtenus.
--

2 (edited by kercyr 2013-08-26 14:34:14)

Re: xml utf-8 xmldom : encodage XML : "output is not an XML document"

FICHIER VBS :
---------------------------------------
'Pour obtenir la liste des processus réseaux en écoute sous Windows
'Utilisation de la commande NETSTAT
' netstat -ano
'
'Option Explicit
Dim TXT_FILE,COMMAND_ECHO1,COMMAND_NETSTAT_ANO,COMMAND_ECHO2,COMMAND_ANALYSE,XML_FILE,XML_FILE_G,oShell0,oShell1
'
Set TXT_FILE = CreateObject("WScript.Shell")
'
TXT_FILE = "cmd /C c:\nmsa\ocsagent\bin\plugins\RESULTNETSTAT.txt"
COMMAND_NETSTAT_ANO=("cmd /C netstat -ano > c:\nmsa\ocsagent\bin\plugins\RESULTNETSTAT.txt")
COMMAND_ANALYSE=("cmd /C c:\nmsa\ocsagent\bin\plugins\NETSTAT_ANALYSIS.cmd")
XML_FILE=("C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTAT.xml")
XML_FILE_G=("C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml")

'
'Création du fichier RESULTNETSTAT.TXT
    'SET oShell0 = WScript.CreateObject("WSCript.shell")
    'oShell0.run TXT_FILE,0,true
'Liste Processus en écoute NETSTAT -ano
    'wscript.echo "NETSTAT -ano dans RESULTNETSTAT.txt : DEBUT"
    SET oShell1 = WScript.CreateObject("WSCript.shell")
    oShell1.run COMMAND_NETSTAT_ANO,0, true
    'wscript.echo "NETSTAT -ano dans RESULTNETSTAT.txt : FIN"

DIM filesys,oShell
SET filesys = CreateObject("Scripting.FileSystemObject")
SET oShell = WScript.CreateObject("WSCript.shell")
'Analyse du fichier résultat et transformation en fichier XML
'wscript.echo "Analyse du fichier résultat et transformation en fichier XML"
    oShell.run COMMAND_ANALYSE,0, true
    '
    '
    'wscript.echo "Affichage du Résultat dans le fichier RESULTNETSTATG.xml"
    DIM filesys4, readfile4, contents4,Result4
    SET filesys4 = CreateObject("Scripting.FileSystemObject")
    SET readfile4 = filesys4.OpenTextFile("C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml",1)
    SET WshShell = CreateObject("WScript.Shell")
        DO UNTIL readfile4.AtEndOfStream
            contents4 = readfile4.ReadLine
            WScript.Echo contents4
        LOOP
    readfile4.close
    '
    '
    'Vérification de la présence du fichier RESULTNETSTATG.xmls
If (filesys.FileExists (XML_FILE_G)) Then
    'Le fichier RESULTNETSTATG.xml existe
    'wscript.echo "Le fichier RESULTNETSTATG.xml existe"
    Set xmlDoc = CreateObject("Microsoft.XMLDOM")
    xmlDoc.Async = "false"
    'wscript.echo "Chargement Load du fichier RESULTNETSTATG.xml : DEBUT"
    xmlDoc.Load(XML_FILE_G)
    strComputer = "."
   wscript.echo "<PROCLAN_NETSTAT_CHAPTER>"
    'Lecture du fichier RESULTNETSTATG.xml et attribution des valeurs aux variables
    'wscript.echo "Lancement For Each 1...."
    For Each ComputersElement In xmlDoc.selectNodes("/PROCS")
    'wscript.echo "For Each 1 ...lancé..."
    'wscript.echo "Lancement For Each 2...."
        For Each ComputerElement In xmlDoc.selectNodes("/PROC/PROC")
    '        wscript.echo "For Each 2...lancé..."
            oProtocol = ComputersElement.getAttribute("PROTOCOL")
            oLocalAddress = ComputersElement.getAttribute("LOCAL_ADDRESS")
            oForeignAddress = ComputersElement.getAttribute("Foreign_Address")
            oState = ComputersElement.getAttribute("STATE")
            oPID  = ComputersElement.getAttribute("PID")
        '
            Wscript.Echo "<PROC>"
            Wscript.Echo "<PROTOCOL />"
            Wscript.Echo "<PROTOCOL>" & oProtocol & "</PROTOCOL>"
            Wscript.Echo "<LOCAL_ADDRESS />"
            Wscript.Echo "<LOCAL_ADDRESS>" & oLocalAddress & "</LOCAL_ADDRESS>"
            Wscript.Echo "<Foreign_Address />"
            Wscript.Echo "<Foreign_Address>" & oForeignAddress & "</Foreign_Address>"
            Wscript.Echo "<STATE />"
            Wscript.Echo "<STATE>" & oState & "</STATE>"
            Wscript.Echo "<PID />"
            Wscript.Echo "<PID>" & oPID & "</PID>"
            Wscript.Echo "</PROC>"
        '
            writeXML oProtocol,oLocalAddress,oForeignAddress,oState,oPID
        Next
    Next
    'wscript.echo "</PROCLAN_NETSTAT_CHAPTER>"
    'wscript.echo "Chargement Load du fichier RESULTNETSTATG.xml : FIN"
End If
'
' Affichage des valeurs
    'wscript.echo "Affichage des valeurs"
Sub writeXML(oPROTOCOL,oLOCAL_ADDRESS,oForeign_Address,oSTATE,oPID)
  'wscript.echo "Affichage des valeurs : ligne 1"
  Wscript.Echo "<PROC>"
  If IsNull(oPROTOCOL) OR (oPROTOCOL = "") Then
      Wscript.Echo "<PROTOCOL />"
  Else
      Wscript.Echo "<PROTOCOL>" & replaceSpecialCar(oPROTOCOL) & "</PROTOCOL>"
  End If
  If IsNull(oLOCAL_ADDRESS) OR (oLOCAL_ADDRESS = "") Then
      Wscript.Echo "<LOCAL_ADDRESS />"
  Else
      Wscript.Echo "<LOCAL_ADDRESS>" & replaceSpecialCar(oLOCAL_ADDRESS) & "</LOCAL_ADDRESS>"
  End If
  If IsNull(oForeign_Address) OR (oForeign_Address = "") Then
      Wscript.Echo "<Foreign_Address />"
  Else
      Wscript.Echo "<Foreign_Address>" & replaceSpecialCar(oForeign_Address) & "</Foreign_Address>"
  End If
  If IsNull(oSTATE) OR (oSTATE = "") Then
      Wscript.Echo "<STATE />"
  Else
      Wscript.Echo "<STATE>" & replaceSpecialCar(oSTATE) & "</STATE>"
  End If
  If IsNull(oPID) OR (oPID = "") Then
      Wscript.Echo "<PID />"
  Else
      Wscript.Echo "<PID>" & replaceSpecialCar(oPID) & "</PID>"
  End If
  Wscript.Echo "</PROC>"
End Sub
'
'Wscript.Echo "Remplacement des caractères speciaux"
Function replaceSpecialCar(sText)
    If IsNull(sText) Then Exit Function
    Dim arrSpecCar(87,2)
    arrSpecCar(0,0) = "À"
        arrSpecCar(0,1) = "A"
    arrSpecCar(1,0) = "Á"
        arrSpecCar(1,1) = "A"
    arrSpecCar(2,0) = "Â"
        arrSpecCar(2,1) = "A"
    arrSpecCar(3,0) = "Ã"
        arrSpecCar(3,1) = "A"
    arrSpecCar(4,0) = "Ä"
        arrSpecCar(4,1) = "A"
    arrSpecCar(5,0) = "Å"
        arrSpecCar(5,1) = "A"
    arrSpecCar(6,0) = "à"
        arrSpecCar(6,1) = "a"
    arrSpecCar(7,0) = "á"
        arrSpecCar(7,1) = "a"
    arrSpecCar(8,0) = "â"
        arrSpecCar(8,1) = "a"
    arrSpecCar(9,0) = "ã"
        arrSpecCar(9,1) = "a"
    arrSpecCar(10,0)= "ä"
        arrSpecCar(10,1)= "a"
    arrSpecCar(11,0)= "å"
        arrSpecCar(11,1)= "a"
    arrSpecCar(12,0)= "Ò"
        arrSpecCar(12,1)= "O"
    arrSpecCar(13,0)= "Ó"
        arrSpecCar(13,1)= "O"
    arrSpecCar(14,0)= "Ô"
        arrSpecCar(14,1)= "O"
    arrSpecCar(15,0)= "Õ"
        arrSpecCar(15,1)= "O"
    arrSpecCar(16,0)= "Ö"
        arrSpecCar(16,1)= "O"
    arrSpecCar(17,0)= "Ø"
        arrSpecCar(17,1)= "O"
    arrSpecCar(18,0)= "ò"
        arrSpecCar(18,1)= "o"
    arrSpecCar(19,0)= "ó"
        arrSpecCar(19,1)= "o"
    arrSpecCar(20,0)= "ô"
        arrSpecCar(20,1)= "o"
    arrSpecCar(21,0)= "õ"
        arrSpecCar(21,1)= "o"
    arrSpecCar(22,0)= "ö"
        arrSpecCar(22,1)= "o"
    arrSpecCar(23,0)= "ø"
        arrSpecCar(23,1)= "o"
    arrSpecCar(24,0)= "È"
        arrSpecCar(24,1)= "E"
    arrSpecCar(25,0)= "É"
        arrSpecCar(25,1)= "E"
    arrSpecCar(26,0)= "Ê"
        arrSpecCar(26,1)= "E"
    arrSpecCar(27,0)= "Ë"
        arrSpecCar(27,1)= "E"
    arrSpecCar(28,0)= "è"
        arrSpecCar(28,1)= "e"
    arrSpecCar(29,0)= "é"
        arrSpecCar(29,1)= "e"
    arrSpecCar(30,0)= "ê"
        arrSpecCar(30,1)= "e"
    arrSpecCar(31,0)= "ë"
        arrSpecCar(31,1)= "e"
    arrSpecCar(32,0)= "Ç"
        arrSpecCar(32,1)= "C"
    arrSpecCar(33,0)= "ç"
        arrSpecCar(33,1)= "c"
    arrSpecCar(34,0)= "Ì"
        arrSpecCar(34,1)= "I"
    arrSpecCar(35,0)= "Í"
        arrSpecCar(35,1)= "I"
    arrSpecCar(36,0)= "Î"
        arrSpecCar(36,1)= "I"
    arrSpecCar(37,0)= "Ï"
        arrSpecCar(37,1)= "I"
    arrSpecCar(38,0)= "ì"
        arrSpecCar(38,1)= "i"
    arrSpecCar(39,0)= "í"
        arrSpecCar(39,1)= "i"
    arrSpecCar(40,0)= "î"
        arrSpecCar(40,1)= "i"
    arrSpecCar(41,0)= "ï"
        arrSpecCar(41,1)= "i"
    arrSpecCar(42,0)= "Ù"
        arrSpecCar(42,1)= "U"
    arrSpecCar(43,0)= "Ú"
        arrSpecCar(43,1)= "U"
    arrSpecCar(44,0)= "Û"
        arrSpecCar(44,1)= "U"
    arrSpecCar(45,0)= "Ü"
        arrSpecCar(45,1)= "U"
    arrSpecCar(46,0)= "ù"
        arrSpecCar(46,1)= "u"
    arrSpecCar(47,0)= "ú"
        arrSpecCar(47,1)= "u"
    arrSpecCar(48,0)= "û"
        arrSpecCar(48,1)= "u"
    arrSpecCar(49,0)= "ü"
        arrSpecCar(49,1)= "u"
    arrSpecCar(50,0)= "ÿ"
        arrSpecCar(50,1)= "y"
    arrSpecCar(51,0)= "Ñ"
        arrSpecCar(51,1)= "N"
    arrSpecCar(52,0)= "ñ"
        arrSpecCar(52,1)= "n"
    arrSpecCar(53,0)= "¢"
        arrSpecCar(53,1)= "cent"
    arrSpecCar(54,0)= "ß"
        arrSpecCar(54,1)= "beta"
    arrSpecCar(55,0)= "¥"
        arrSpecCar(55,1)= "yen"
    arrSpecCar(56,0)= "€"
        arrSpecCar(56,1)= "euro"
    arrSpecCar(57,0)= "£"
        arrSpecCar(57,1)= "pounds"
    arrSpecCar(58,0)= "™"
        arrSpecCar(58,1)= "trademark"
    arrSpecCar(59,0)= "©"
        arrSpecCar(59,1)= "copyright"
    arrSpecCar(60,0)= "®"
        arrSpecCar(60,1)= "registered"
    arrSpecCar(61,0)= "ª"
        arrSpecCar(61,1)= "exp(a)"
    arrSpecCar(62,0)= "×"
        arrSpecCar(62,1)= "x"
    arrSpecCar(63,0)= "÷"
        arrSpecCar(63,1)= "/"
    arrSpecCar(64,0)= "±"
        arrSpecCar(64,1)= "+/-"
    arrSpecCar(65,0)= "²"
        arrSpecCar(65,1)= "exp(2)"
    arrSpecCar(66,0)= "³"
        arrSpecCar(66,1)= "exp(3)"
    arrSpecCar(67,0)= "¼"
        arrSpecCar(67,1)= "1/4"
    arrSpecCar(68,0)= "½"
        arrSpecCar(68,1)= "1/2"
    arrSpecCar(69,0)= "¾"
        arrSpecCar(69,1)= "3/4"
    arrSpecCar(70,0)= "µ"
        arrSpecCar(70,1)= "u"
    arrSpecCar(71,0)= "¿"
        arrSpecCar(71,1)= "?"
    arrSpecCar(72,0)= "¶"
        arrSpecCar(72,1)= "paragraph"
    arrSpecCar(73,0)= "·"
        arrSpecCar(73,1)= "."
    arrSpecCar(74,0)= "¸"
        arrSpecCar(74,1)= ","
    arrSpecCar(75,0)= "º"
        arrSpecCar(75,1)= "o"
    arrSpecCar(76,0)= "°"
        arrSpecCar(76,1)= "degre"
    arrSpecCar(77,0)= "¯"
        arrSpecCar(77,1)= "_"
    arrSpecCar(78,0)= "§"
        arrSpecCar(78,1)= "paragraph"
    arrSpecCar(79,0)= "…"
        arrSpecCar(79,1)= "..."
    arrSpecCar(80,0)= "¤"
        arrSpecCar(80,1)= "¤"
    arrSpecCar(81,0)= "¦"
        arrSpecCar(81,1)= "pipe"
    arrSpecCar(82,0)= "‡"
        arrSpecCar(82,1)= "dagger"
    arrSpecCar(83,0)= "¬"
        arrSpecCar(83,1)= "-"
    arrSpecCar(84,0)= "ˆ"
        arrSpecCar(84,1)= " "
    arrSpecCar(85,0)= "¨"
        arrSpecCar(85,1)= " "
    arrSpecCar(86,0)= "‰"
        arrSpecCar(86,1)= "0/00"
    arrSpecCar(87,0)= "œ"
        arrSpecCar(87,1)= "oe"

    ' pour chaque element du tableau
    For i=0 To UBound(arrSpecCar,1)
        ' on remplace
        sText = Replace(sText, arrSpecCar(i,0), arrSpecCar(i,1))
    Next
    ' puis on affecte le retour
    replaceSpecialCar = sText
End Function

-----------------------------------------------------------------------------------------

-----------------------------------------------------------------------------------------
FICHIER NETSTAT_ANALYSIS.cmd
-------------------------------------------
@ECHO ON
::
del /F C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTAT.xml
del /F C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml
::
cmd /c echo (" <?xml version="1.0" encoding="UTF-8"?> ") > c:\nmsa\ocsagent\bin\plugins\RESULTCODAGE.txt
cmd /c echo " <PROCS> " > c:\nmsa\ocsagent\bin\plugins\RESULTECHO1.txt
cmd /c echo " </PROCS> " > c:\nmsa\ocsagent\bin\plugins\RESULTECHO2.txt
::
FOR /F "eol=  skip=3 tokens=1,2,3,4,5 delims= " %%i in (C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTAT.txt) do (@echo " <PROC> <PROTOCOL> %%i </PROTOCOL> <LOCAL_ADDRESS> %%j </LOCAL_ADDRESS> <Foreign_Address> %%k </Foreign_Addresss> <STATE> %%l </STATE> <PID> %%m </PID> </PROC> ") >> C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTAT.xml
::
FOR /F "eol=  tokens=1,2,3,4,5 delims= " %%m in (C:\nmsa\ocsagent\bin\Plugins\RESULTCODAGE.txt) do (@echo %%n %%o %%p > C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml)
::
FOR /F "eol=  tokens=1,2,3 delims= " %%t in (C:\nmsa\ocsagent\bin\Plugins\RESULTECHO1.txt) do (@echo %%u >> C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml)
::
FOR /F "eol= skip=1 tokens=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19 delims= " %%A in (C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTAT.XML) do (@echo %%B %%C %%D %%E %%F %%G %%H %%I %%J %%K %%L %%M %%N %%O %%P %%Q %%R) >> "C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.XML
::
FOR /F "eol=  tokens=1,2,3 delims= " %%w in (C:\nmsa\ocsagent\bin\Plugins\RESULTECHO2.txt) do (@echo %%x ) >> C:\nmsa\ocsagent\bin\Plugins\RESULTNETSTATG.xml)
-----------------------------------------------------------------------------------------

Re: xml utf-8 xmldom : encodage XML : "output is not an XML document"

RESULTAT OBTENU DANS UN FICHIER RESULTATNETSTATG.xml
-----------------------------------------------------------------------------------------


<?xml version="1.0" encoding="UTF-8"?>
<PROCS>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:80 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1080 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:135 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 704 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:443 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1080 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:445 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:3306 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1272 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:3389 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 2600 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:47001 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:49152 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 416 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:49153 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 796 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:49154 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 844 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:49155 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 520 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:49156 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 512 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:139 </LOCAL_ADDRESS> <Foreign_Address> 0.0.0.0:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:3389 </LOCAL_ADDRESS> <Foreign_Address> 192.168.0.34:3101 </Foreign_Addresss> <STATE> ESTABLISHED </STATE> <PID> 2600 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:49187 </LOCAL_ADDRESS> <Foreign_Address> 192.168.0.34:445 </Foreign_Addresss> <STATE> ESTABLISHED </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:80 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1080 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:135 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 704 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:443 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1080 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:445 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:3306 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 1272 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:3389 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 2600 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:47001 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 4 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:49152 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 416 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:49153 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 796 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:49154 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 844 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:49155 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 520 </PID> </PROC>
<PROC> <PROTOCOL> TCP </PROTOCOL> <LOCAL_ADDRESS> [::]:49156 </LOCAL_ADDRESS> <Foreign_Address> [::]:0 </Foreign_Addresss> <STATE> LISTENING </STATE> <PID> 512 </PID> </PROC>
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:123 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 892 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:500 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:3544 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:4500 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 0.0.0.0:5355 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 984 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:137 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 4 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:138 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 4 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> 192.168.1.215:51742 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> [::]:123 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 892 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> [::]:500 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> [::]:4500 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 844 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> [::]:5355 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 984 </STATE> <PID> </PID> </PROC> "
<PROC> <PROTOCOL> UDP </PROTOCOL> <LOCAL_ADDRESS> [fe80::f56f:fcc:42d8:490d%11]:546 </LOCAL_ADDRESS> <Foreign_Address> *:* </Foreign_Addresss> <STATE> 796 </STATE> <PID> </PID> </PROC> "
-----------------------------------------------------------------------------------------

Re: xml utf-8 xmldom : encodage XML : "output is not an XML document"

Je constate effectivement des caractères tel que "
Il manque la fin du fichier </PROCS>
...
c'est en cours ...
...