Showing posts with label Tips and Tricks. Show all posts
Showing posts with label Tips and Tricks. Show all posts

Wednesday, February 11, 2009

Microsoft: ‘Consistent exploit code likely’ for IE vulnerabilities

Microsoft today shipped four bulletins with patches for at least 8 documented security vulnerabilities affecting Windows users and warned that “consistent exploit code could be easily crafted” to launch attacks via the Internet Explorer browser.

The Patch Tuesday batch includes fixes for a pair of code execution holes in IE, two bugs in the Microsoft Exchange Server, a remote code execution issue in the Microsoft SQL Server, and three separate flaws haunting users of Microsoft Office Visio.

The Internet Explorer bulletin (MS09-002) should be treated with urgency because the flaws can be exploited to launch drive-by download attacks.

* This security update is rated Critical for Internet Explorer 7 running on supported editions of Windows XP and Windows Vista. For Internet Explorer 7 running on supported editions of Windows Server 2003 and Windows Server 2008, this security update is rated Moderate.

The Microsoft warning that consistent exploit code was likely suggests that it’s very easy for an attacker to host a specially crafted Web site and attack unpatched users who surfed to the rigged Web site.

* The attacker could also take advantage of compromised Web sites and Web sites that accept or host user-provided content or advertisements. These Web sites could contain specially crafted content that could exploit this vulnerability.

Enterprise administrators will also want to pay special attention to the Microsoft Exchange update (MS09-003) which covers two different vulnerabilities that expose users to code execution or denial-of-service attacks.

Microsoft explains:

* The first vulnerability could allow remote code execution if a specially crafted TNEF message is sent to a Microsoft Exchange Server. An attacker who successfully exploited this vulnerability could take complete control of the affected system with Exchange Server service account privileges. The second vulnerability could allow denial of service if a specially crafted MAPI command is sent to a Microsoft Exchange Server. An attacker who successfully exploited this vulnerability could cause the Microsoft Exchange System Attendant service and other services that use the EMSMDB32 provider to stop responding.

The company says it expects to see “inconsistent exploit code” published for this bulletin. However, nCircle director of security operations Andrew Storms says this is a very serious problem.

“This vulnerability means that any cybercriminal sending a well crafted email attachment to an enterprise could gain complete control over the server and gaining one of the keys to the kingdom,” Storms said.

“All kinds of highly confidential and proprietary information pass through an Exchange server every day. Gaining control over it and its content would be a gold mine to any cyber criminal,” he added.

Monday, October 27, 2008

Hiding PHP as another language


In general, security by obscurity is one of the weakest forms of security.
But in some cases, every little bit of extra security is desirable.



A few simple techniques can help to hide PHP, possibly slowing
down an attacker who is attempting to discover weaknesses in your
system. By setting expose_php = off in your php.ini file, you
reduce the amount of information available to them.



Another tactic is to configure web servers such as apache to
parse different filetypes through PHP, either with an .htaccess

directive, or in the apache configuration file itself. You can
then use misleading file extensions:


 Hiding PHP as another language


# Make PHP code look like other code types

AddType application/x-httpd-php .asp .py .pl


Read more about Hiding PHP

Monday, October 6, 2008

Earn Money with AdSense for Search Create your custom search engine and earn money with AdSense

AdSense is one of the most popular services from Google, because it helps people earn money just with a simple ad placed on their websites. Related to AdSense, Custom Search Engine is another innovative product provided by Google that also brings
money after users have placed a search engine on their webpages.

So, what's the relation between these two products? Well, Google said that if you link your Custom Search Engine to your AdSense for Search account, you can boost your earnings with ease.

"We've heard it time and time again: as publishers, you want to give your users a relevant search experience on your websites. You want the power of Google search, and you want to make it your own. And then, of course, you want to make money from this search engine, not spend time and money building it. Well, here's news you can use -- now you can do all this with Google's Custom Search Engine (CSE).

With CSE, you can create a highly customized and (free) tailored search experience for your users that reflects your knowledge and expertise. You place this search engine on your site and, if you've got an AdSense for search account, you can link your CSE to it and make money from the resulting traffic.

In a few simple steps you can create a CSE that looks and feels like your own, prioritizes or restricts content based on what you specify, as well as open your search engine index to trusted members of your community so they can contribute to its comprehensiveness and relevance," Jennifer Hyman - CSE Product Marketing Manager said on the official blog.

Friday, October 3, 2008

AutoComplete Widgets

JAVASCRIPT DHTML TUTORIALS » Ajax Layer » AutoComplete Widgets »


AutoComplete Widget

Wednesday, October 1, 2008

How to animate an element's position using the Motion subclass

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

<html>

<head>

<title>Motion Example - Basic</title>

<style type="text/css">

/*

Copyright (c) 2006, Yahoo! Inc. All rights reserved.

Code licensed under the BSD License:

http://developer.yahoo.net/yui/license.txt

Version: 0.10.0

*/



body {

   
margin:0;

   
font:small arial;

}



h1 {

   
color:#666;

   
margin:0;

   
font:bold 150% palatino, georgia;

}



#hd img {

   
vertical-align:middle;

}



#hd h1 {

   
display:inline;

   
margin:0 0 0 20px;

   
vertical-align:middle;

}



ul, li {

   
margin:0;

   
padding:0;

   
list-style:none;

}



#doc {

   
margin:10px;

}



#examples {

   
margin:60px 40px;

}



#examples li {

   
margin-bottom:1em;

}



#examples li a {

   
color:#666;

   
font:85% verdana;

}



#demo {

   
background:#ccc;

   
font:100%/1.2em arial;

   
width:10px;

   
height:10px;

}



#animation-demo-scroll #demo p {

   
width:600px;

}



#animation-demo-motion #demo {

   
color:yellow;

   
font-size:0;

}



#animation-demo-size-plus #demo, #animation-demo-fade #demo, #animation-demo-colors #demo {

   
background:#ccc;

   
font:100%/1.2em arial;

   
width:200px;

   
height:200px;

}

#animation-demo-colors #demo {

   
border:3px solid #c3c;

}



#animation-demo-scroll #demo {

   
width:400px;

   
height:200px;

   
overflow:auto;

}



#animation-demo-colors #demo {



}



#target {

   
background:red;

   
font-size:0;

   
position:absolute;

   
left:300px;top:300px;

   
width:10px;

   
height:10px;

}



</style>



<script type="text/javascript" src="./build/yahoo/yahoo.js"></script>

<script type="text/javascript" src="./build/event/event.js"></script>

<script type="text/javascript" src="./build/dom/dom.js"></script>

<script type="text/javascript" src="./build/animation/animation.js"></script>



<script type="text/javascript">

YAHOO.example.init = function() {   

   
var anim = new YAHOO.util.Motion('demo', { points: { to: YAHOO.util.Dom.getXY('target') } });

   
YAHOO.util.Event.on(document, 'click', anim.animate, anim, true);

};



YAHOO.util.Event.onAvailable('demo', YAHOO.example.init);

</script>



</head>

<body id="animation-demo-motion">

<div id="doc">

   
<h1>Motion Example - Basic</h1>

   
<p>This example demonstrates how to animate an element's position using the Motion subclass.</p>

   
<p>Click anywhere to start animation.</p>

   
<div id="demo"></div>  

   
<div id="target"></div>

</div>

</body>

</html>






Yui required !!!!

Try it online

Accessing the Elements of a Form



<HTML>

<HEAD>

<TITLE>Multiform Document Example</TITLE>

<SCRIPT LANGUAGE="JavaScript"><!--

function displayFormData() {

 
win2=open("","window2")

 
win2.document.open("text/plain")

 
win2.document.writeln("This document has "+document.forms.length+" forms.")

 
var i=0;

 
var j=0;

 
for(i=0;i<document.forms.length;++i) {

  
win2.document.writeln("Form "+i+" has "+ document.forms[i].elements.length+" elements.")

  
for(j=0;j<document.forms[i].elements.length;++j) {

   
win2.document.writeln((j+1)+" A "+ document.forms[i].elements[j].type+" element.")

  
}

 
}

 
win2.document.close()

 
return false

}

// --></SCRIPT>

</HEAD>

<BODY>

<FORM ACTION="nothing" onSubmit="return displayFormData()">

<H2>Form 1</H2>

<P>Text field: <INPUT TYPE="TEXT" NAME="f1-1" VALUE="Sample text"></P>

<P>Password field: <INPUT TYPE="PASSWORD" NAME="f1-2"></P>

<P>Text area field: <TEXTAREA ROWS="4" COLS="30" NAME="f1-3">Text</TEXTAREA></P>

<P><INPUT TYPE="SUBMIT" NAME="f1-4" VALUE="Submit">

<INPUT TYPE="RESET" NAME="f1-5"></P>

</FORM>

<HR>

<FORM>

<H2>Form 2</H2>

<P><INPUT TYPE="CHECKBOX" NAME="f2-1" VALUE="1" CHECKED>A</P>

<P><INPUT TYPE="CHECKBOX" NAME="f2-1" VALUE="2">B</P>

<P><INPUT TYPE="CHECKBOX" NAME="f2-1" VALUE="3">C</P>

<P><INPUT TYPE="RADIO" NAME="f2-2" VALUE="1">D</P>

<P><INPUT TYPE="RADIO" NAME="f2-2" VALUE="2" CHECKED> E</P>

<P><INPUT TYPE="RADIO" NAME="f2-2" VALUE="3">F</P>

<INPUT TYPE="FILE" NAME="f2-3">

</FORM>

<HR>

<FORM>

<H2>Form 3</H2>

<INPUT TYPE="HIDDEN" NAME="f3-1">

<SELECT NAME="f3-2" SIZE="4">

<OPTION VALUE="">Item 1</OPTION>

<OPTION VALUE="">Item 2</OPTION>

<OPTION VALUE="" SELECTED>Item 3</OPTION>

<OPTION VALUE="">Item 4</OPTION>

<OPTION VALUE="">Item 5</OPTION>

</SELECT>

</FORM>

</BODY>

</HTML>

           


       
Try Online

Friday, September 26, 2008

The Basic Rules of Search Engine Optimization

Search engine optimization is a process that generates traffic for your website. The SEO (Search Engine Optimization) includes principles and algorithms, mainly related to the website design, capable of generating actions to improve the search engine ranking for your webpages. Increasing the value of your page's rank, the quality and quantity of visitors will be increased too. For example, the main search engines, Google and Yahoo will index your website and will rank pages according to some complex algorithms.

In order to obtain higher page ranks, you should have in mind some basic rules that will assure your SEO success. There are two types of SEO: on page SEO and off page optimization. In both cases, you should check if your site design matches the SEO main conditions:

1. Optimization of URLs - It is recommended to use short URLs titles having static character (for example .html pages), clearly named and if is possible to contain relevant keywords for your page's content. The ideal case is when the relevant keywords are even in the domain name. When choosing the keywords for meta tags you should think what keywords or key phrases you would type to search for a certain page or content on a given search engine.

2. Optimization of the page title tag - The search engine spider will look also in your page title tag for relevant keywords that describe the content of your webpages. As a consequence, the title tag should contain from one two three keywords or key phrases related or present in the page's content. You should also limit the length of your page title to 50 characters or less. And of course, every page should have a distinctive page title, easy to understand for crawlers. The abusive use of keywords will induce a decrease of page rank.

3. Optimization of the website content - The website content is among other factors that will decide the page rank. You should know that crawlers or spiders (the search engines indexing tools) do not index the content of pictures or a javascript action for example. In case you use extensively images for your page content, you should provide a detailed description for every picture. The main idea you should follow when you add content to your website is to maintain simplicity. In conclusion, the text should be present on your webpages in a higher percent as compared to images, javascripts or others. You must also provide fresh content to your visitors periodically.

4. Optimization of the site navigation system - You should build a site map having links that point to the main parts of your site. For example, Google uses your sitemap to analyze the structure of your website. All links must point to valid webpages. It is recommended to check the validity of your site navigation structure using a link checker. You should pay attention to the internal links that should contain keywords, and the number of internal links must be increased in order to provide a clear site hierarchy and an effective navigation system.

As a suggestion, the use of CSS (Cascading Style Sheets) will determine a simple and yet rapid site structure, easy to understand for search engine spiders. The external links must point only to quality sites (for example, your page rank will be increased when you link to sites having higher search engine ranks themselves). You should not use links to "link farms". There must be also other links from weblogs, forums or other sites that point to your site. You can achieve this goal by performing a link inter-change process.

5. Optimization of the general site structure - In case your site design does not allow the SEO modifications mentioned, you should change the overall site structure. You can simply do this by using a ready-made CMS (a content management system). It is easy to use and in most cases it's created having the SEO principles in mind, so you will have to manage only the content, without being concerned owith the design.

These rules are not enough to obtain the maximal search engine rank, but they should be taken as a good start for a complete strategy of search engine optimization.