Change Ant version in NetBeans easy.

NetBeans IDE 6.0 Preview (M9, build 070502)

NetBeans IDE 6.0 M9 come with Ant build tool version 1.7, which syntaxs of build file maybe different with Ant version 1.6. When I use NetBeans with default Ant(1.7) build Nutch i got error.

D:\javas\NBeansProject6\nutch\build.xml:61: Specify at least one source--a file or resource collection.BUILD FAILED (total time: 0 seconds)

I'm too lazy to correct the build.xml to correct the problem, so i go to change Ant version to elder one (v.1.6) and try to build it again. then I got .....BUILD SUCCESSFUL (total time: 16 seconds)

------------------------
To change Ant goto >
Tools > Options > Miscellaneous > Ant > Ant Home

Change Ant Home to ant version that you prefer. Easy?

Computer security basics

Computer security basics
It's useful to understand what computer security protects against, the respective defense mechanisms, and the different terminologies associated with it. 

Threats
Threats -- attacks against computer security -- can be broadly categorized as:

Secrecy attacks: Attempts to steal confidential information either by exploiting weaknesses in cryptographic algorithms or by other means. 
Integrity attacks: Attempts to alter information with some selfish or malicious intent. Integrity attacks, it should be noted, can also be accidental. 
Availability attacks: Attempts to disrupt a system's normal operations. Availability attacks are also referred to by the recently popularized term, denial of service (DoS) attacks. 



Several attacks fall into one or more of the categories mentioned above. Examples include:

A brute force attack typically involves searching every key until the right one unlocks the door. While that may seem like an expensive operation, in reality it is possible to preen the search using specialized tools. 
A Trojan horse attack involves planting an enemy as an insider in such a way that it's not apparently noticeable. A computer virus serves as a common Trojan horse example. 
A person-in-the-middle attack intercepts communication between two parties without their knowledge. They assume that they're communicating normally. 



Other attacks include: birthday attack, dictionary attack, meet-in-the-middle attack, and so on. (For a more comprehensive discussion, see Bruce Schneier's Applied Cryptography in Resources.) 

Protections
To shield against security threats, there are a variety of protection mechanisms. Historically, defense mechanisms have involved erecting some sort of a wall or boundary, commonly referred to as a perimeter defense.

Firewalls, a fairly successful example of perimeter defense, separate internal (private) and external (public) networks, and provide a central point of control for a corporate policy. However, firewalls increasingly allow select forms of traffic -- HTTP for example -- to cross over. 

A virtual private network (VPN), which provides the same security level as a private network while still using a shared network, serves as another protection example. 

Cryptography
Cryptography and cryptanalysis, its related field, concerns itself with the design and analysis of algorithms for encrypting and decrypting information. We'll discuss cryptography's vital relationship to security in the sections below. 

Confidentiality
Confidentiality is the process of protecting data from unauthorized use or users. Simply put, it means that only the intended recipient of a message can make sense of it. 

If you're exchanging sensitive information with someone else, you want to be absolutely sure that only the intended recipient of the message can make sense of the message and, in the eventuality that it falls into wrong hands, the message becomes effectively useless. Confidentiality is accomplished by some form of cryptographic technique. 

Authentication
The authentication process confirms the user's identity. The user could be a software entity or a human. A principal is the party whose identity is verified. Associated with a principal is a set of credentials. Usually, authentication confirms identity by some secret information -- a password, for example -- known only to the user and the authenticator. Beyond passwords, more sophisticated security schemes employ advanced techniques such as smart cards or biometrics (finger printing, retinal scans, and so on) for authentication. 

Once authentication is established, access to the user (or generally principal) is governed by the access control mechanisms in force. 

Kerberos -- based on keys and encryption -- demonstrates an early authentication technology. It uses timestamps -- sessions remain valid for a defined time period -- to achieve that. To work properly, Kerberos fundamentally assumes that the clocks in a distributed system are synchronized. 

Public key infrastructure (PKI), discussed in sections below, represents a more general authentication solution. 

The Java Authentication and Authorization Service (JAAS) framework supplements the Java 2 platform with user-based authentication and access control capabilities. JAAS is a standard extension to the Java 2 Software Development Kit, v 1.3. 

Integrity
Let's say that you sent an electronic check. When the bank ultimately receives the check, it needs to be sure that the payment amount has not been tampered, a security concept known as integrity. 

Nonrepudiation
In the electronic check scenario outlined above, if you indeed sent the check, there ought to be no way you can deny it. Nonrepudiation provides undeniable evidence of actions such as proof of origin of data to the recipient or receipt of data to the sender. 

Auditing and logs
Keeping a record of resource access that was granted or denied might be useful for audit purposes later. To that end, auditing and logs serve the useful purposes of preventing a break-in or analyzing a break-in post mortem. 

Policy and access control
A security policy focuses on controlling access to protected data. It's important that the security enforcing mechanisms should be flexible enough to enforce the policy. That is referred to as keeping the policy separate from the mechanism. While that decision might be based on authorizing access to a resource based on the identity of principal, it is often easier to administer access control based on roles. Each principal is mapped to a unique role for the purposes of access control. It is often implemented as a list or matrix enumerating the access that different users/roles have to the different protected resources.  

Benchmarks Game : Safari 3 Claimed, It's performance better IE7 and Firefox


Several days ago Apple had released  Safari browser platform on window, Steve Jobs the CEO and Apple marketing claim that Safari browser performance advantages over IE nad Firefox. Truely I never know Safari before but my friends that us Mac os told me that, So i download Safari and found that the browser still beta version. After install it's no problem to run the browser but i very upset with it's performance, that surely form my experience that it's slower than IE7 and firefox exactly.
Serveral days later, there have some benchmark form Wired Blogs that show performance of Safari3 is slower than IE7 and Firefox. They had tested by use Safari, Firefox and IE7 open Google Mail's login page, login to the mail until Google Mail index page appeared with 50 message and all graphics and message status indicators, lunch Google Calendar and display two subscripbed calendars.


Result is Firefox is fastest and IE7 is still better than Safari.

This benchmark form http://blog.wired.com/monkeybites/2007/06/wired_news_benc.html

Apple's Safari browser now for Windows



Apple launched a version of its Safari web browser for Windows-based PCs on Monday, pitting it against Microsoft's Internet Explorer and Mozilla's Firefox.
"What we've got here is the most innovative browser in the world and the most powerful browser in the world," said Apple CEO Steve Jobs said during his keynote speech at the company's Worldwide Developers Conference.
Safari, which was released a few years ago for Apple's Macintosh computers, has captured about 5 per cent of the world's market share for internet browsers with more than 18 million users, Jobs said.
Internet Explorer is the predominant browser with a 78 per cent share, while Firefox has rapidly climbed to gain about 15 per cent of the market, he said. Like the other web browsers, Safari is available as a free download.
Jobs claimed Safari performs twice as fast as its competitors.




Build for iPhone
Never one to disappoint his audience, the iconic chief executive - in his final highlight of his 1 1/2 hour speech - also pulled out an iPhone and told the thousands of developers before him that the highly anticipated hybrid smart phone and iPod will run Safari.
That means, Jobs said, that any application meant to run on the Safari browser for Macs would also be fully accessible and compatible with the iPhone.
Jobs also announced that Apple is opening the core of its iPhone to independent developers, giving them a way to have customised programs ready when the devices hit the market June 29.
"You can begin building your iPhone applications today. We are very excited about this," Jobs said.
The announcement was met with cheers from developers that had been pressuring the Cupertino, California-based company for a way to tailor applications to iPhones.
"You can build custom applications for the iPhone that have the look and feel of the phone," Jobs told the crowd.
"You can build fantastic applications for iPhone. I can't wait to run all the applications you're going to build."


Harry Potter games for Macs
US computer game giant Electronic Arts has announced that it is tailoring a new Harry Potter game and other titles for Apple's Macintosh computers.
"The only thing better than living on a Mac is living in Hogwarts," EA's chief creative officer Bing Gordon said as he demonstrated the Potter game at the opening of Apple's Worldwide Developers Conference in San Francisco.
On a large screen behind the stage where Gordon stood with Jobs, an animated Potter cast spells and made candles float in the Great Hall of Hogwarts School of Witchcraft and Wizardry made famous in the best-selling series of books by J.K. Rowling.
Harry Potter and the Order of the Phoenix for Macintosh computers, powered by Intel chips, will be released in July along with EA titles Battlefield 2142, Command and Conquer, and Need for Speed Carbon, according to Gordon.

A sample Google MAP web

Serveral days ago i have regist Google map and try to use the map in my homepage.

In this page http://www.thaibloger.com/guides/chumphon/chumporn_guide.html.
This page is guideline to travel Chumphon Islands National Park of Thailand.
For now Information in the page still be thai language, i hope to update it soon,
But not too soon. Because my English is not quite good.

About Iframes and it's restriction...

What is Iframe??
Iframe or Inline Frames is an new element of html document that allow you to load html files inth and existing document.
What browser support iframe?
IE4+, Netscape6+, Firefox, Mozilla, Opera and other modern browsers all support iframes.

An External html document can be loaded into iframe without disrupting the rest of the document. Styling and Scripting in iframe can be manipulate properties in the iframe itself as original html document. The document style does not inherit from containing document.
JavaScript can be used to communicate betaween document in iframe and containing document.

Note
When you try to access properties of document that loaded into iframe, make sure that the document loaded into iframe come from same domain, else you got "permission denied".
....event it's the sub domain you still got "permission denied".

Next.. article I will show some example of scripting with iframe..

Netbeans and Thai language

Netbeans and Thai language
Netbeans and Thailanguage, Output window.

Serveral days ago..I have a little test on Netbean 5.5
In netbean 5.5 create and application for test whit some "Hello world" but in Thai
"สวัสดีชาวโลก"

---------------------------------------------
public class Main {
public static void main(String[] args) {
System.out.println("สวัสดีชาวโลก");
}
}
---------------------------------------------

then build project i got this error.

---------------------------------------------
Compiling 1 source file to D:\javas\projects\test\build\classesD:\javas\projects\test\src\test\Main.java:28: unmappable character for encoding Cp1252
System.out.println("สวัสดีชาวโล�");
1 errorBUILD FAILED (total time: 0 seconds)
---------------------------------------------


What that!! Um that because default JVM default property "file.encoding" is Cp1252
from http://java.sun.com/j2se/1.4.2/docs/guide/intl/encoding.doc.html
windows-1252 Cp1252 is--> Windows Latin-1
you can check it by printout property by --> System.getProperty("file.encoding");

then how i can solve the problem???
Ans Menu Tools>Options>advanced options>java soucrces>default encoding
set it to UTF8

then compile again you should got BUILD SUCCESSFUL

but
when you run it in netbeans. You will got
สวัสดีชาวโล�
some special font that you can't read in Thai....What da Heck???

Ans netbeans default output use UTF8 then how to fix this?
from project>right click>properties>Run
put this -Dfile.encoding=TIS620 in to Vm Options
then run again.... You still got ÊÇÑÊ´ÕªÒÇâÅ¡ copy it to notepad you should read this
text..??

because
Output window of netbeans cannot set font to other than it default font Monospaced.

สุดเซ็ง ใน Netbean 6 ที่กำลังจะออกก็ยังไม่ได้แก้ตรงนี้ วันนี้เข้าไป request feature นี้แล้ว
แต่ไม่รู้มันจะทำให้หรือเปล่า?? จะแก้เองก็เกรงใจ ไว้ว่างๆ แล้วค่อยมาดูแล้วกัน สุดเซ็ง.
จบข่าว.....

Netbeans 5.5 Can't even set font in output window

After try to explore how to set font in Output window of Netbeans.
I Found that I can't set Netbeans output window font.

Why i have to change output window's font?
Because i have to use other language on output window for testing.

I hope that next version Netbeans 6 would have this feature.!

Using Jakarta Jmeter through Proxy

Using Jakarta Jmeter through Proxy
to config Jmeter to send request through proxy..in startup script "jmeter.bat" or "jmeter" shell script you should set paramterat last line.

-Dhttp.proxyHost=yourproxy -Dhttp.proxyPort=80

then your script may look like this

%JM_START% %JM_LAUNCH% %JVM_ARGS% %ARGS% -jar "%JMETER_BIN%ApacheJMeter.jar" -Dhttp.proxyHost=yourproxy -Dhttp.proxyPort=80 %JMETER_CMD_LINE_ARGS%