2G Lab, the company of pod2g

The well known hacker pod2g has created his own company. It’s called 2G Lab and they are working on application development and security research.

Here is the original post :

You reader certainly know that I have not been really present in the security field since a few months now.
The reason of this was the creation of my company, 2G Lab, focusing on 2 different areas : development and security research.
Now that our first application, named podDJ is out to the AppStore, we will focus on both subjects.
If you have a project that you would like 2G Lab to work on, contact us: contact at 2g-lab dot com.
Best wishes to you all,
Cyril (@pod2g)

Source : http://www.pod2g.org/2013/01/2g-lab.html?spref=tw&m=1


Some tips in Java

You are programming in Java and you want to know some simple but new things? So read this post and maybe you’ll know some new things 🙂 .

The first tip is about the focus. What is a focus? If you have a JTextField and you want to have the cursor automatically activated in it when you open the window, you put a focus. Here is the code :


SwingUtilities.invokeLater(new Runnable()
public void run()




Here the JTextField name is jtf and you have to do this like this if you want to put the pan.setVisible(true); after the focus (for example if you want to put the “visibility” at the end of the code).

Now you have a grid of buttons and you want to know which one is clicked. It’s very simple, you just have to set a name to your buttons :

JButton[][] myGrid = new JButton [10][10];

for(int i = 0; i < myGrid.length; i++ ) {
for(int j = 0; j < myGrid[0].length; j++ ) {
myGrid[i][j] = new JButton();
myGrid[i][j].setName("" + i + j);


Here I put the name with myGrid[i][j].setName("" + i + j); and the name will be 00 for the first button and so on. And now if you want to have the name, you must do this in a listener :

String name = ((JButton) ev.getSource()).getName();

int a = name.charAt(0)-48;
int b = name.charAt(1)-48;

And here you have the name and you can use it as you want.

A last very little tip (it’s pretty sure you already know it), how to unactivate a button. It’s very simple, when you’ve created your button, just put this :


You have to change button with the name of your button.

It’s the end of this post. If you have any question, feel free to ask. Hope it will help you and I’ll try to make an other post about tips in Java.

How to run little java programs in MobileTerminal

Here is a new little tutorial that shows you how to run littles Java programs in MobileTerminal.

Needed for this tutorial :

  • A jailbroken iDevice
  • MobileTerminal installed on it

First, go in Cydia. Be sure to have the developer “profile” turned on (Manage –>; Settings –>; Developer). Now, you have to search this :

  • iPhone/Java (it will install others needed packages).
  • Jikes.



Just install these packages. Now, you have to do a Java file. For example, you can just type this in the file (name it test.java in this case) :

public class test{
public static void main (String args[]){
System.out.println("Hello World!");

You can do it on your iDevice if you have iFile or any other file manager or you can do it on your computer and then transfer it with iFunBox (in this tutorial, I put the file in /var/mobile).

Now that you’ve made all what is written, open MobileTerminal. Type jikes test.java -cp /usr/lib/rt.jar (or the name_of_your_file.java).


Type on the “return” button. You have now to type java test (or the_name_of_your_file), just type one more time on the “return” button, wait a bit and it will show the message 🙂 .


If you have any tip or problem, you can post a comment 😉 .

JsAnywhere, a little app to code in JavaScript

So today I’m going to present you an app with which you can program and run in JavaScript.


What’s different between this app and Buffer Editor?
In Buffer Editor, it has the colors for the instructions, but you can’t run the code. Here in JsAnywhere, you can do your little webpage (you can mannage the HTML and CSS) and run the code. You can’t use all the features (like the instruction “prompt”, it doesn’t work).

So you can download this app and the when you open it, you’ll have something like this (or no project). To create one, just tap the top right button with a “+”.




When you want to load a project, just tap on it and it will be oppened. Now you can see that there’s a default JavaScript file, a default HTML page and a default CSS file. You can change what you want in them.



So here I just changed the code to have an alert with “35”. I’ve also changed a little bit the HTML page ().


Now when you tap the little button “Run” (just after the “CSS” button), the program will show an alert with “35”, and you’ve done it :).

You can change some settings in the native Settings app.


Note : the instruction prompt("What you want"); doesn’t work in this app.
You have to type “Javascript Anywhere” in the AppStore to find this app.

The real advantage of this app is that you can run your code and see if it works. It’s also a free app.

The inconveniences of the app are that there isn’t any colors and that there’s some advertising on it (that’s why I put my iPhone in airplane mode).

Enjoy it and put your feedback here :). If you have any tip or so, share them here too.

Buffer Editor, a really good app for developers

I’ve bought a new app yesterday and I can say that it’s a really good application for all the people who love to develop some programs, website or anything like this.


So with this app you can develop in a lot of different programming languages. At the begining, you have to create a new folder, or a new project. You can even take/put some files on your Dropbox account.


Once you have your project, you can create a file (top right button) or create a folder into the projet (top left button).


Now, your file is created and just tap on it to open it. You can begin to put some code in it and normally the code will take some colors, it depends on the instruction you write.
Note : with one or two themes, it doesn’t take good colors, you’re free to choose the theme you want).



You can hide the keyboard or write the code in fullscreen mode. You can put a lot of file extensions and you can write in a lot of programming languages.




You can change the theme of the editor. I put a theme that has a dark background, but there’s also some with white background. The colors of the instructions change when you change the theme. You can change the font type and the font size.



So that was a little article about this very cool app. The inconvenience are that it has some bugs, you can’t run the code and it’s also a paid app (4 CHF, I think it’s 3.99USD).

If you like or use this app, feel free to comment and say how you find it. If you have some tips, comment also to share them.

The DM Team

So I’ve a new team and a new project. I made a team with a friend and the name of our group is “DM Team”.

We love developping and so we made this little team just to work with each other and to enjoy the development. We will make a website and after that some programs. We haven’t got the same knowledge in the programming language, but we will try to do some cool stuf.

You can find our blog here :
DM Team’s Blog

And you can follow us on Twitter :

Begin in iOs jailbreak development on your iDevice 2

I made a post which explain how to make a basic tweak that changes the color of the screenshot. Now, if you have a good knowledge in Objective-c, you can make others (and better) tweaks.

When you want to make a tweak, you hook a system file to inject a new code to be run. You can hook a lot of different files that make a lot of different things. But to hook a file, you have to know his name and the methods that are in it.

The files are in .h, you can find them in /var/sdk/usr/local/include. The most you will normally use are in /var/sdk/usr/local/include/SpringBoard. To open a file, just tap on it and choose “Text editor” or maybe it will be open without asking that. When you are in it, you can see all the methods (-(void)…).

In the first post, we made a tweak that changes the color of the screenshot. The second line of the code was :

%hook SBScreenFlash

Then we put :

So we were working on the method -(void)flashColor:(UIColor*)color; that you can see in the file SBScreenFlash.h.

Now you can search into the files (the names are really easy to understand, I mean you understand easily what the file do and it’s the same for the metods).

Enjoy jailbreak development.