@@ -86,6 +86,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
8686 $ length = intval ($ result ['ContentLength ' ]);
8787 if ($ length > 0 ){
8888 $ content = $ this ->geCiContentInfo ($ result , $ length );
89+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
90+ libxml_disable_entity_loader (true );
91+ }
8992 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
9093 $ xmlData = json_decode (json_encode ($ obj ),true );
9194 if ($ picRuleSize == 1 && isset ($ xmlData ['ProcessResults ' ]['Object ' ])){
@@ -101,6 +104,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
101104 $ length = intval ($ result ['ContentLength ' ]);
102105 if ($ length > 0 ){
103106 $ content = $ this ->geCiContentInfo ($ result , $ length );
107+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
108+ libxml_disable_entity_loader (true );
109+ }
104110 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
105111 $ arr = json_decode (json_encode ($ obj ),true );
106112 $ result ['GuetzliStatus ' ] = isset ($ arr [0 ]) ? $ arr [0 ] : '' ;
@@ -111,6 +117,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
111117 $ length = intval ($ result ['ContentLength ' ]);
112118 if ($ length > 0 ){
113119 $ content = $ this ->geCiContentInfo ($ result , $ length );
120+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
121+ libxml_disable_entity_loader (true );
122+ }
114123 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
115124 $ arr = json_decode (json_encode ($ obj ),true );
116125 $ result ['CIStatus ' ] = isset ($ arr [0 ]) ? $ arr [0 ] : '' ;
@@ -122,6 +131,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
122131 $ length = intval ($ result ['ContentLength ' ]);
123132 if ($ length > 0 ){
124133 $ content = $ this ->geCiContentInfo ($ result , $ length );
134+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
135+ libxml_disable_entity_loader (true );
136+ }
125137 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
126138 $ arr = json_decode (json_encode ($ obj ),true );
127139 $ result ['OriginProtectStatus ' ] = isset ($ arr [0 ]) ? $ arr [0 ] : '' ;
@@ -133,6 +145,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
133145 $ length = intval ($ result ['ContentLength ' ]);
134146 if ($ length > 0 ){
135147 $ content = $ this ->geCiContentInfo ($ result , $ length );
148+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
149+ libxml_disable_entity_loader (true );
150+ }
136151 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
137152 $ arr = json_decode (json_encode ($ obj ),true );
138153 $ result ['Hotlink ' ] = $ arr ;
@@ -144,6 +159,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
144159 $ length = intval ($ result ['ContentLength ' ]);
145160 if ($ length > 0 ){
146161 $ content = $ this ->geCiContentInfo ($ result , $ length );
162+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
163+ libxml_disable_entity_loader (true );
164+ }
147165 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
148166 $ arr = json_decode (json_encode ($ obj ),true );
149167 $ result ['TranslationResult ' ] = isset ($ arr [0 ]) ? $ arr [0 ] : '' ;
@@ -204,6 +222,9 @@ public function ciContentInfoTransformer(CommandInterface $command, Result $resu
204222 $ length = intval ($ result ['ContentLength ' ]);
205223 if ($ length > 0 ){
206224 $ content = $ this ->geCiContentInfo ($ result , $ length );
225+ if (version_compare (PHP_VERSION , '8.0.0 ' , '< ' )) {
226+ libxml_disable_entity_loader (true );
227+ }
207228 $ obj = simplexml_load_string ($ content , "SimpleXMLElement " , LIBXML_NOCDATA );
208229 $ xmlData = json_decode (json_encode ($ obj ),true );
209230 $ result ['Response ' ] = $ xmlData ;
0 commit comments