How do I convert this file (Attached) to a readable text file (its XML code)
I found code here and there but doesnt work. I want to grab the whole file and dump it back out as readable text.
Thanks!
Printable View
How do I convert this file (Attached) to a readable text file (its XML code)
I found code here and there but doesnt work. I want to grab the whole file and dump it back out as readable text.
Thanks!
Get a Hex editor and use it to open the file... You can then examine the contents to see if it's convertible to readable xml. I tried it found some parts are readable, other parts are just garbage. Is it encrypted?
It seems to be a file containing binary data which can not entirely be interpreted as text.
It contains null bytes, among other non-printable characters. Where did you get this file from?
if it really is XML, it should already be in text format... that's the point of XML .... unless as stanav mention, it's been encrypted... in which case, you'll need the accompanying decryption method and keys to get it back.
-tg
Took a look at it.... it appears to be a C string resource file.... not an XML file....
-tg
:) its actually an Ipod Touch 2.2.1 "strings" file
its styled like XML and reads like xml when converted...
it comes right off the touch like that.
after converted it will look like this:
etc etcQuote:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>ACCEPT</key>
<string>Accept</string>
<key>AFTER_CLTM_SHUTDOWN_BODY</key>
<string>iPhone shut down due to temperature.</string>
<key>AIRPLANE_CELL_PROMPT</key>
<string>You must disable airplane mode to access data.</string>
<key>AIRPLANE_CELL_PROMPT_SMS</key>
<string>You must disable airplane mode to send or receive text messages.</string>
<key>AIRPLANE_DATA_OK</key>
<string>OK</string>
<key>AIRPLANE_DATA_PROMPT</key>
<string>Turn off Airplane Mode or use Wi-Fi to access data</string>
<key>AIRPLANE_DATA_SETTINGS</key>
<string>Settings</string>
<key>ALARM</key>
<string>Alarm</string>
<key>ALARM_LOCK_LABEL</key>
<string>slide to stop alarm</string>
<key>ALARM_OK</key>
<string>OK</string>
<key>ALARM_SNOOZE</key>
<string>Snooze</string>
people have done this before... but all links o the converter used are dead. it was an online converted. Im guessing that anything that is not readable should be ignored?
If this is some sort of Ipod file...there must be some documentation on the format of these files that you can use to write your own converter.
It's not an xml file.... it can be converted into an xml file... but it is not inherently an xml file. It is a string resource file. I've seen similar formats in C string resource files before. As a side note... that seems like a horrible format for key/value pairs.... it's relying heavily on being red in order and that nothing goes wrong with it when being created or read back.... but that might be just me.
-tg
of course its horrible.. its APPLE! lol
and yeah, it probably is a C file. it is designed to be read in order, just once.
Once its loaded into memory.. doesnt matter
I just need to converted into a regular text file :)
ok, so how can i do this?
Can i just convert what can be converted and ignore the rest?
wait... does this help anyone?
I found a site that does this online....
i uploaded the file clicked convert and this is what it says:
converting...
BinaryToXML:
Offsets are 2 bytes
Object Refs are 2 bytes
There are 588 objects in the file
The top object is at 0
The Offset Table is at offset 17128
Int Lengths = 776
Misc Lengths = 1
String Lengths = 15055
Unique Strings = 587
In order to get the data you want, you'll probably have to parse the file. Here is a java implementation, maybe that can get you started:
http://www.java2s.com/Open-Source/Ja...arser.java.htm