Skip to content

Commit

Permalink
Remove the '|| usage' in the triton shell script.
Browse files Browse the repository at this point in the history
If an analyzed binary returns something like -1 (sometime it does),
the usage message of the triton shell script is displayed - it
should not.

Below, an example of this wrong behavior.

$ ./triton -startAnalysis check ./samples/crackmes/crackme_xor a
[Start analysis]
...
----- Model -----
UNSAT
-----------------
0x4005b2        mov eax, 0x1                            #20 = (_ bv1 32)
0x4005b7        jmp 0x4005c8                            n/a
0x4005c8        pop rbp                                 #21 = #1
                                                        #22 = (bvadd #0(_ bv8 64))
[Stop analysis]
loose
Triton binary analyzer usage: triton MODE [MODE_ARGS] EXEC [EXEC_ARGS]\n
Available modes are:
 -startAnalysis <func_name>  Start the analysis the scope of the
function
 -detectFormatString         Enable the format string detection analysis
  • Loading branch information
JonathanSalwan committed Feb 6, 2015
1 parent b17e41c commit 7aca6ca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ pintool.log
*.o
*.so
note_perso
smt2_branches
3 changes: 2 additions & 1 deletion triton
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,5 @@ if [ ! -x ${EXEC} ]; then
fi

# Running Triton
${ROOT}/../../../pin -t ${ROOT}/triton.so ${MODE} ${MODE_ARGS} -- ${EXEC} ${EXEC_ARGS} || usage
${ROOT}/../../../pin -t ${ROOT}/triton.so ${MODE} ${MODE_ARGS} -- ${EXEC} ${EXEC_ARGS}

0 comments on commit 7aca6ca

Please sign in to comment.