[Soot-list] Bug in traps translation

Martin Schäf martinschaef at gmail.com
Wed Sep 10 10:44:20 EDT 2014


Just tested it with the latest version, result is the same... and, thats a
bug I'd say. Looks like you are extending the trap until the next label and
thats why the throw-statement slips in there. The bytecode certainly works
as it should.
Cheers,
Martin

On Tue, Sep 9, 2014 at 11:33 PM, Bodden, Eric <eric.bodden at sit.fraunhofer.de
> wrote:

> Hmmm, I just took another look at this.
>
> I think I misinterpreted something... It seems like in the bytecode the
> trap ends just before the "throw", right? That would make much more sense.
> If that's true then this indeed seems to be a bug in the Jimple generation.
> It's too bad that you are using 2.5.0.  I wonder if this problem still
> exists in the current version.
>
> Eric
>
> On 10.09.2014, at 07:59, Bodden, Eric <eric.bodden at sit.fraunhofer.de>
> wrote:
>
> > Hi Martin.
> >
> >> Which means that block4 goes into an infinite loop if I'm not
> mistaking, right?
> >
> > Well, it means that it _might_ go into an infinite loop - which it
> _will_ if the unlocking fails at runtime. Again it seems like the compiler
> is at error here. Soot only translates 1:1 what's stated in the bytecode.
> >
> >> That causes a lot of headache in my analysis... is there an easy way I
> can fix that? Btw., I'm still on soot-2.5.0 because of the line number
> problem. Someone mentioned I can fix that by using coffi instead of ASM but
> I have no idea what that means :(
> >
> > With 2.5.0 you don't need to worry. You are using Coffi anyway. But as I
> wrote, this is not the issue. The bytecode already looks odd. So for Soot
> there is not much it could do. You could just write a Soot pass that finds
> such situations and somehow modifies the Jimple to make them go away
> (diverging from the semantics of the original bytecode). It would be better
> to figure out why the compiler is doing what it's doing.
> >
> > Best wishes,
> > Eric
> > _______________________________________________
> > Soot-list mailing list
> > Soot-list at CS.McGill.CA
> > https://mailman.CS.McGill.CA/mailman/listinfo/soot-list
>
> --
> Prof. Eric Bodden, Ph.D., http://sse.ec-spride.de/ http://bodden.de/
> Head of Secure Software Engineering  at Fraunhofer SIT, TU Darmstadt and
> EC SPRIDE
> Tel: +49 6151 16-75422    Fax: +49 6151 16-72051
> Room 3.2.14, Mornewegstr. 30, 64293 Darmstadt
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20140910/3e326c3e/attachment.html 


More information about the Soot-list mailing list