Ubuntu continues to make great strides with improvement to the User Interface for the ‘common’ user. Unfortunately this sometimes comes at the cost of security. 12.10 added a “Guest” account to the launch screen, to allow a new session to be opened. This is not always useful as it represents a potential security concern.
A single line command and reboot will remove it:
sudo sh -c 'echo "allow-guest=false" >> /etc/lightdm/lightdm.conf'
Similarly “Remote Login” can also be hidden/removed.
sudo sh -c 'echo "greeter-show-remote-login=false" >> /etc/lightdm/lightdm.conf'
After updating the JDK on my development workstations, NetBeans started reporting the following at each start up.
Cannot locate java installation in specified jdkhome:
Do you want to try to use default version?
[ Yes | No ]
Thankfully, after a little searching, I found that the solution is very simple. You can change the value or comment it out with a # in:
C:\Program Files\NetBeans #.#.#\etc\netbeans.conf
As I often find myself cleaning up legacy webapp codebases, this item seems pretty common, particularly for sites that were using TABLE based layouts.
<table cellpadding="0" cellspacing="0">
With modern browsers, this is easily accomplished with some simple CSS, as you might need some distinction between different tables or have some cases that require padding or spacing, you MIGHT consider assigning a CSS class as I have below.
border-collapse: collapse; /* 'cellspacing=0' equivalent */
padding: 0; /* 'cellpadding=0' equivalent */
Categories: Uncategorized cell, cellpadding, cellspacing, css, html, padding, remove, spacing, table, td, th, xhtml
Oddly, there are two separate sites, but I believe that they have the same content:
I’ve often found that most JSP developers are uncertain as to why their HTML output contains a lot of extra blank-lines, tabs and carriage returns. White space included in the template text of JSP pages is preserved by default. This can have undesirable effects. For example, a carriage return added after a taglib directive would be added to the response output as an extra line. This cruft is known as WhiteSpace, and it is responsible for a lot of wasted bandwidth and many spacing issues in HTML designs.
- Developers that only use WYSIWYG editors are never even aware of the extra spacing within JSP source code.
- Developers that work in source code often want to format the markup to allow for better visualization and readability of the source code.
- Most IDE’s do not show the developers the special characters within the editor environment, external text editors such as NotePad++ and TextPad can be configured to show them.
Here’s a few suggested approaches on removing these, first development items:
- Remove comments:
- Remove any (and all) JSP style comments
<%-- comment --%> as each line in them will result in a carriage return being sent to the browser.
- While you are at it, remove HTML comments
<!-- comment --> as they often expose potential attack vectors for individuals trying to hack your website.
- Combine your JSP directives,
<%@page %> or
<jsp:directive.page /> into a single entry.
- Open and close all tags on a single line when possible.
Compiler options are possible for some platforms:
- The page directive on each JSP can contain the argument to tell the compiler to trim the space in individual JSP’s:
<jsp:directive.page language="java" pageEncoding="utf-8" trimDirectiveWhitespaces="true" />
- For Tomcat (and others?) web.xml can be edited to contain the following in the
- For Tomcat (and others?) web.xml can be edited to contain the following for the
- The deployment descriptor can also be used to do so by adding a
trim-directive-whitespaces element to a
jsp-property-group element in the deployment descriptor and set it to
- Some IDE’s expose the attribute, NetBeans 5.5 uses the following:
- Open the deployment descriptor file in the editor.
- Click the Pages button at the top of the editor.
- Select a JSP property group.
- Select the Trim Directive Whitespaces checkbox.
- Save the deployment descriptor.
- Custom tag authors can eliminate white space from the output generated by a tag file by setting the
trimDirectiveWhiteSpace attribute of the tag directive to
JSP Version Matrix for common servers:
|Apache Tomcat 7.0.x
|Apache Tomcat 6.0.x
|Apache Tomcat 5.5.x
|Apache Tomcat 4.1.x
|Apache Tomcat 3.3.x
|IBM WebSphere Application Server 7.x
|IBM WebSphere Application Server 6.x
|IBM WebSphere Application Server 5.x
Categories: Uncategorized bandwidth, compiler, deployment, descriptor, directive, jsp, network, performance, tags, trim, whitespace
This one is quite eye-opening. I recently suffered a hard-drive failure and was unable to boot either operating system in a multi-boot environment. The only item not backed up was a large number of photos and movies that I had accumulated and intended to burn to a CD/DVD. Using a ‘Live’ Ubuntu CD, I was able to use the Foremost program to analyze the drive media and locate all JPG and MPG files and copy them to a ’safe’ location.
What’s frightening here is that these files are not located by their filenames, but by their contents… largely the first few bytes of the file itself when stored on disk. In my experience, Foremost was easily able to parse NTFS and EXT4 partitions.
Word to the wise… this is only possible if you do not use encryption to obscure the data on the drive itself. I’d personally recommend enabling the options provided by your operating system itself if you store sensitive data. Alternately, software like TrueCrypt can be used to hide specific assets.
While it was not technically a personal computer, the Atari 2600 was one of the first pieces of technology that I had experience with in my youth. I’ll likely outline the progression of machines/operating systems in a future post.
I’ve heard about Stella for quite a while, but never had any time to fiddle with it. Recently I found that Ubuntu includes an installer for it and took a chance look. Other versions are available for MacOS and Windows.
I also found a few websites that contain ROM images for the emulator and was playing some of my old games in a matter of minutes.
For those legal types out there… I actually do own the games that I played, in fact, they are currently boxed up in my basement.
Happy Retro Gaming!!!
Categories: Uncategorized 2600, arcade, atari, emulation, emulator, free, gaming, linux, open-source, stella, ubuntu, windows