Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

As what title said, how should I open this file? It was a executable(application/x-executable) file.

Thank you.

share|improve this question

closed as not constructive by david6, aquaherd, Jorge Castro, Kevin Bowen, Thomas Ward Jun 22 '13 at 0:25

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

I don't think it's reasonable to present a random binary file on here without any further information. Even worse, if other users are tempted to run the file (as you've said it's executable), they are extremely vulnerable to any malicious payload. I'm not saying that you are malicious; just that in general this is the reason that presenting this kind of question shouldn't be acceptable. Instead, can you explain what the file is, where you got it from and what you expect Ubuntu to do with it? This might help others to solve your problem safely. – Robie Basak Jun 21 '13 at 14:18
I wish to scan its vulnerability and find the vulnerability function. I am sorry, I am new. I didn't know this kind of file is malicious. But my quiz requirement ask me to solve this file by scanning its vulnerability by providing the answer How? – Bubitata Jun 21 '13 at 14:25
It's not that it necessarily is malicious, it's that it very easily could be (which is why I won't be making any attempts to download, let alone open, it). Especially since you're talking about vulnerabilities (which are often exploited to embed or execute some kind of malicious code) - coupled with the fact that you are posting something listed as an application as your first post, it's the sort of thing that can make people nervous (not that I wouldn't still be wary of someone doing that as their 50th post) – Jez W Jun 21 '13 at 14:30
If you're not sure, then do not try to run it. This could compromise your computer. Please don't ask anyone else to try to open or run it, either. To ask how to examine a potentially malicious file is a reasonable question, though. – Robie Basak Jun 21 '13 at 14:32
Please could you edit your question accordingly? – Robie Basak Jun 21 '13 at 14:33

That all depends on what it is...

Generally speaking, you can use gedit testing to open the file and view the contents, if it's in some plaintext format.

I see you've tagged the question as "executable", so I assume it's a program of some sort? If that's the case, first verify the following: Do you know exactly where the file came from originally; Do you trust the source; Do you know exactly what the program is supposed to do? If the answer to any one of these three questions is "no", then please do NOT try to run it.

If (and ONLY if) the answer to all of the above was "yes", though, then in a terminal you would navigate to the folder containing the file and write chmod +x testing; ./testing to execute it. The first changes the file permission so that it is executable, and the second tells it to run. I hope you'll forgive me for not trying this myself though, since running anonymous executables isn't really the best of ideas.

share|improve this answer
Yes, I trust the source. Actually I am doing some simple challenge. It was all in hex form when opened with gedit. I get this file from removing part of hex(jpg image file) and I get this executable. It was a correct file. Now I wish to open it or scan this file's vulnerability. Any ideas? Thanks – Bubitata Jun 21 '13 at 14:19
Wait, so... it was a jpg, and then you edited it and it ended up recognised as an application? That usually means that you've corrupted it and it can't be opened conventionally. I don't know how to answer the rest of what you're asking, to be honest... – Jez W Jun 21 '13 at 14:27
Erm.. It was actually a Steganography technique. I am a Security student. They can hide information inside an image. I just decrypted them and get this file. It was not corrupted. But the problem now is that I do not know how to open it. – Bubitata Jun 21 '13 at 14:29
"corrupted" in as much as "can't be opened in its original context". If you remove something from the plaintext / hex of a JPG, it's unlikely that it can be opened as a jpg any more. The closest I know of to getting the source is some kind of text editor, beyond that I don't know (that you as a security student were surprised at people's mistrust of a random executable slightly baffles me, though) – Jez W Jun 21 '13 at 14:47
I am sososo new to do harm to other people yet. Haha, I just sms my lecturer, unfortunately, he do not have laptop at home. But he said I am going the good direction by having the error when opening it. He ask me to use a debugger to find the vulnerabilities of the file. Do you know any debugger in ubuntu? Can you intro it to me? Thanks.. – Bubitata Jun 21 '13 at 14:49

have you tried ./testing in your terminal? if it's not working due to permission, try to type chmod +x ./testing before redoing ./testing

(you need to have your testing file in your working directory)

share|improve this answer
I tried them all, I typed ls -l, I get -rwxrwr -x 1, for ./testing, I get Segmentation fault(core dumped). chmod +x I get nothing. Please help.. – Bubitata Jun 21 '13 at 14:17
if you get a seg fault, then it might because your program has errors in it. What is it supposed to do, and in what environement was it compiled ? – Aserre Jun 21 '13 at 14:20
I am not sure about that, I am doing simple challenge(quiz). So now I actually wish to open it and see the codes inside. – Bubitata Jun 21 '13 at 14:21
editing it with gedit made it crash. Maybe the binary file was meant to run on windows ? – Aserre Jun 21 '13 at 14:25
I don't think so, the requirement of the quiz said everything should be done in ubuntu 12.04 – Bubitata Jun 21 '13 at 14:26

Not the answer you're looking for? Browse other questions tagged or ask your own question.