Thursday, January 10, 2008
Updates: Captcha Design v1.0
Wednesday, January 9, 2008
Technical: Applied Colouring to Text
ColoringAttributes textColor = new ColoringAttributes();
textColor.setColor(1.0f, 0.0f, 0.0f);
textAppear.setColoringAttributes(textColor);
textAppear.setMaterial(new Material());

Monday, January 7, 2008
Technical: Text3D/Font3D in Java3D
Font3D arial = new Font3D(
new Font("Arial", Font.PLAIN, 1),
new FontExtrusion());
Text3D text = new Text3D(arial, "3DText");
/** End of sample code */

Technical: Our First MIDlet
We get our hands on J2ME, where we create our first MIDlet program. Let's look at the following code and I'll explain some fundamentals of MIDlet.
import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
public class HelloMIDlet extends MIDlet {
public void startApp() {
System.out.println("Hello World");
}
public void pauseApp() {
}
public void destroyApp(boolean unconditional) {
}
}
javax.microedition.midlet.MIDlet. It defines three life-cycle notification methods: startApp(), pauseApp(), and destroyApp().
Now into the lifecycle of a MIDlet. When the MIDlet object is made by calling its constructor, the application is said to be in thePaused state. We move the application to Active state by calling the startApp() method. From the Active state, we can take the application back to Paused state by calling the pauseApp() method. The thing to remember here is that startApp() and pauseApp() can be called multiple times in an application's life time. Lastly when u want to terminate the application, u calls the destroyApp() method. destroyApp() accepts a boolean parameter and if it is true, the MIDlet quit, no matter what it is currently doing. However if this is false, the application can survive termination by throwing a MIDletStateChangeException. If any runtime exception occurs within the destroyApp() method, it is ignored and the application is terminated immediately.
Tutorial here.Sunday, January 6, 2008
Meeting: 05 Jan 2008 (Msn)

Agenda: System Design and Implementation
The following were discussed:
- System Implementation Progress
- Developement server setup completed by ADRIAN. The following has installed :
- Apache Tomcat Server
- JAVA SDK
- JAVA 3D
- Computer web page registration form demo prototype completed by SEBASTIAN.
- MIDLET registration form demo prototype completed by ADRIAN. - Captcha Design
- Testing on basic 3D objects on M3D platform and Display in J2ME emulator. By LEXIS.
- Testing on basic 3D objects on Java3D and display in Applet. By ALAN
Conclusion : Effect achieved by both JAVA3D and M3D is different.
- Question and problem raised by team
It is not efficient to compute 2 different pieces of code(1 for normal computer web browsers and 1 for MIDLET).
Reasons :
1. Need to maintain 2 pieces of codes.
2. Is not scaleble.
3. Captcha design end result might be different.
Suggestion : We will need to display the Captcha output as image format, for instant, JPEG or PNG which acceptable by both normal web browsers and MIDLET platform.
Attendence:
- SEAH CHOON YEE, SEBASTIAN
- CHEE SUEN SIANG, ALAN
- CHIA U-MENG, ADRIAN
- OW WAI LEONG, LEXIS
Friday, January 4, 2008
Technical: Our First Java3D
import com.sun.j3d.utils.universe.SimpleUniverse;
import com.sun.j3d.utils.geometry.ColorCube;
import javax.media.j3d.BranchGroup;
public class HelloJava3Da
{
public HelloJava3Da()
{
// Create a virtual universe to contain your scene.
SimpleUniverse universe = new SimpleUniverse();
// Create a data structure to contain a group of objects
BranchGroup group = new BranchGroup();
// Add an object to the group
group.addChild(new ColorCube(0.3));
// Position the viewer so that they are looking at the object
universe.getViewingPlatform().setNominalViewingTransform();
// Add the group of objects to the universe
universe.addBranchGraph(group);
}
public static void main( String[] args )
{
new HelloJava3Da();
}
}
At the Hello3d() constructor, you will see the five lines that perform each of the commented steps. The program displays a glowing cube, the viewer is looking directly at the red face of the cube, so what you actually see is a red square on a black background.
Thursday, January 3, 2008
Meeting: 02 Jan 2008 (Group)
The following were discussed:
- Limitation by WAP browser issue.
It is confirmed by Adrian Choo that we are allowed to choose the mobile application platform to develop the captcha system. Hence the team decided to change the development platform to JAVA as it supports more graphics features.
Below is the new system implementation diagram.
- System development task assigning
Captcha design - in charge by ALAN and LEXIS
System implementation(Web Page form) - in charge by SEBASTIAN
System implementation(MIDLET form) - in charge by ADRIAN - CAPTCHA Design and Implementation
- Team will start to develop the captcha according to the required design which will be able display in all the computer web browser and MIDLET.
- Team will Java3D and M3D technology to develop.
- Team target to show the prototype at session 1 presentation. - System Implementation
- Team will start development on the system to demo the captcha.
- Team require to develop a registration form in computer web page and MIDLET to allow the use of captcha design by ALAN and LEXIS.
- The traffic flow of data must be secured at all the time. - Question and problem raised by team
1. If end users keep requesting the web page and captcha challenge, will it result in DoS?
Solution :Yes, it will as it needs resource to generate captcha challenge, hence we need to prevent end users from repeating request the web service. Few ideals suggested by team:
- Use logging features (Apache Server logs?).
- Use AJAX reduce the web request load.
- Increase the Captcha challenge generation performance.
Conclusion : We will do testing at the end of Session 1 prototype to decide which solution is the best to solve this problems.
2. How do we prevent attackers from Eavesdropping the captcha answer?
Solution : We will use encryption algorithm to hash the correct answer. Answer provided by end users will be hashed and validate with the correct hash answer.
Attendence:
- SEAH CHOON YEE, SEBASTIAN
- CHEE SUEN SIANG, ALAN
- CHIA U-MENG, ADRIAN
- OW WAI LEONG, LEXIS

