Friday, March 24, 2006

Association of Shareware Professionals: Portable Application Description (PAD)

Association of Shareware Professionals: Portable Application Description (PAD): "PAD is the Portable Application Description, and it helps authors provide product descriptions and specifications to online sources in a standard way, using a standard data format that will allow webmasters and program "

Thursday, March 23, 2006

bochs: The Open Source IA-32 Emulation Project (Tech Specs)

bochs: The Open Source IA-32 Emulation Project (Tech Specs)
Welcome to the Bochs IA-32 Emulator Project
Bochs is a highly portable open source IA-32 (x86) PC emulator written in C++, that runs on most popular platforms. It includes emulation of the Intel x86 CPU, common I/O devices, and a custom BIOS. Currently, Bochs can be compiled to emulate a 386, 486, Pentium, Pentium Pro or AMD64 CPU, including optional MMX, SSE, SSE2 and 3DNow! instructions.
Bochs is capable of running most Operating Systems inside the emulation including Linux, DOS, Windows® 95/98 and Windows® NT/2000/XP. Bochs was written by Kevin Lawton and is currently maintained by this project.
Bochs can be compiled and used in a variety of modes, some which are still in development. The 'typical' use of bochs is to provide complete x86 PC emulation, including the x86 processor, hardware devices, and memory. This allows you to run OS's and software within the emulator on your workstation, much like you have a machine inside of a machine. For instance, let's say your workstation is a Unix/X11 workstation, but you want to run Win'95 applications. Bochs will allow you to run Win 95 and associated software on your Unix/X11 workstation, displaying a window on your workstation, simulating a monitor on a PC.

Wednesday, March 22, 2006

How to Shut Down the System

How to Shut Down the System

The following example uses the ExitWindowsEx function to shut down the system. Shutting down flushes file buffers to disk and brings the system to a condition in which it is safe to turn off the computer. The application must first enable the SE_SHUTDOWN_NAME privilege. For more information, see Privileges.

Tuesday, March 21, 2006

GetModuleFileName

GetModuleFileName

Larry Osterman's WebLog : Little known Win32 APIs: DisableThreadLibraryCalls()

Larry Osterman's WebLog : Little known Win32 APIs: DisableThreadLibraryCalls(): "parameter doesn’t care about DLL_THREAD_XXX messages, and thus the loader won’t call into the DLL on threa"

Wednesday, March 15, 2006

PHP AJAX File Upload Progress Meter

PHP AJAX File Upload Progress Meter

This is an AJAX upload progress meter for PHP. The code is released under the GPL.

The author is Joshua Eichorn

It uses the upload progress meter patch and extension from: http://pdoru.from.ro/

For more information read the blog posting about this code

There is also a wiki available where further documentation is being added

AJAX File Upload Progress Meter

This code was originally written using JPSpan but has been updated to use my AJAX library, HTML_AJAX.

Demo: View Demo with a patched PHP

Demo: View Demo without the patch

You can browse the source on SVN, or check it out: http://svn.bluga.net/HTML_AJAX/UploadProgressMeter

Downloads are provided by the svn viewer, there hasn't been a formal release. (Note: this requires you have HTML_AJAX 0.2.5+ installed)

Microsoft.com Advanced Search

Microsoft.com Advanced Search

Utilities/ WinIo/ProcSpy32

Utilities
WinIo

The WinIo library allows 32-bit Windows applications to directly access I/O ports and physical memory. It bypasses Windows protection mechanisms by using a combination of a kernel-mode device driver and several low-level programming techniques.

ProcSpy32

ProcSpy32 is a Visual Basic utility which monitors the execution and termination of processes under Windows 9x. It uses an OCX component and a device driver that work in tandem to receive notifications from the system whenever a process is started or terminated. You are free to use the bundled ProcSpy OCX and its source code for any purpose.

NtDriverList

NtDriverList is a user-mode console application which takes advantage of the undocumented NtQuerySystemInformation API to obtain a list of loaded drivers under Windows NT. Source code is included !

StickyApp32

StickyApp32 is a tiny visual basic application which is resistant to termination attempts from the Windows NT task manager. It does this by establishing a hook on the OpenProcess API and modifying the return value of this function. Complete source code is included !

APISpy32

API spying utilities are the most powerful tools for exploring the internal structure of applications and operating systems. They provide tons of information and enable the user to explore the "guts" of the application under test. Unfortunately, most API spying utilities can monitor only one application at a time and also have the tendency to break apart when used with large pieces of code. APISpy32 is a different type of API interceptor which solves most of these problems. It monitors API calls made by ALL active Windows applications and logs the values of input parameters. This version works under Windows 9x/NT/2000 and ME.

Utilities

Hector's Memos:Where's The Checked Build?

Hector's Memos:Where's The Checked Build?

Date: 29-Aug-03, Modified: 11-Apr-07
From: Hector J. Rodriguez
To: Driver Developers

Re: Where's The Checked Build?


So, where is the checked build download? It's gotten to be like it's some sort of a freakin' test. "If you can't find the checked build, you're not smart enough to write Windows drivers." Caray! If that's the case, then I must be a big pendejo, cuz it took me more than 30 minutes to find the damn thing.

Confused as to what to do with these downloaded executables? If you're frustrated because you can't figure out how to install the checked kernel and HAL for your system from the executable downloads this article points to, check out this memo.



Enabling JIT-attach Debugging

Enabling JIT-attach Debugging
.NET Framework Developer's Guide
Enabling JIT-attach Debugging

JIT-attach debugging is the phrase used to describe attaching a debugger to an executable image that throws an uncaught exception. In unmanaged code, it is what happens when you see a message box that invites you to:

  • Click OK to terminate the program

  • Click CANCEL to debug the program

If you click CANCEL, a debugger is started and attached to the process. The registry key that controls this is called HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\Current Version\AeDebug.

For an application that includes managed code, the common language runtime will present a similar dialog to JIT-attach a debugger. The registry key that controls this option is called HKEY_LOCAL_MACHINE\Software\Microsoft\.NETFramework\DbgJITDebugLaunchSetting.

Alex Fedotov.com - Creating Self-Installing Packages

Alex Fedotov.com - Creating Self-Installing Packages

Self-installing packages usually consist of a small launcher application and an archive that contains the main installer and application components to be installed. The launcher extracts the archive into a temporary directory, runs the main installer, waits for its completion and then deletes temporary files. The launcher must be small and it has to run on any version of Windows.

This article focuses on creating of the self-installing package launcher. It does not explain how to create the main installer. You can use one of commertial packages such as InstallShield for that purpose, or you can write your own installer. This is entirely up to you.

Composing a Self-Installing Package

The first thing we have to decide is which compression algorithm to use. Another question is how to combine the launcher and the archive into a single piece. Remember, we want the launcher to be as small as possible, so an ideal solution would be to use a compression scheme which is already built into the operating system. Windows cabinet files provide reasonably good compression and can be easily expanded using the SetupIterateCabinet function, which we will describe later in this article.

To create a cabinet file you can use the cabarc utility, which is shipped with the Platform SDK. Using this utility is pretty straightforward, just run it without arguments to see the list of available options:

INFO: Tips for Windows NT Driver Developers -- Things to Avoid

SUMMARY
Following are some tips for creating Windows NT device drivers. The tips presented apply to all technologies. You can also use this as a checklist for troubleshooting driver problems.

You need to have a basic knowledge of Windows NT architecture and some device driver development experience to use the information presented below effectively. For more information on device driver development, please see the Windows NT device driver kit (DDK), which is available through MSDN Professional membership.
MORE INFORMATION
Following is a list of things that developers should avoid when working with Windows NT device drivers:


INFO: Tips for Windows NT Driver Developers -- Things to Avoid

Visual C++ Linker Options

LINK is a 32-bit tool that links Common Object File Format (COFF) object files and libraries to create a 32-bit executable (.exe) file or dynamic-link library (DLL).

The table below is a comprehensive list of options for LINK.exe. This section also includes information on:
Compiler-Controlled LINK Options
LINK Input Files
LINK Output
Reserved Words

Linker options specified on the command line are not case sensitive: /base and /BASE mean the same thing.

You can specify some linker options via the comment pragma.
Visual C++ Linker Options

Building and deploying a basic WDF Kernel Mode Driver

At the end of December 2005, Microsoft released the new Windows Driver Foundation. This is a new framework for building windows device drivers. It is a lot more high level than the Windows Driver Model (WDM), and as such it is easier to learn, and less time consuming to develop drivers with.

This article will show you how to code, build and deploy a skeleton WDF Kernel Mode Device Driver.

This article does not explain all the low level concepts behind driver development. To learn these basic concepts, check out the materials mentioned in the ‘Related material’ chapter. This would be far too much to explain in 1 article.

WDF

PECompact

PECompact is a utility of the genre known as "executable packers" or "executable compressors". Executable packers compress executable modules so that their physical size is considerably smaller. At runtime, compressed modules (executables) are rapidly decompressed and reconstructed in memory.

In fact, decompression and reconstruction is so rapid that load time usually improves since the time saved by reading fewer bytes from the disk or network often exceeds the time spent reconstructing and decompressing in memory.

And the compression ratio? It's better than any general purpose compression software like ZIP, RAR, or 7-ZIP. This is because PECompact is optimized for a specific type of file format: executables.

Viruses don't harm ignorance do!

"Everyone has the right to freedom of opinion and expression;
this right includes freedom to hold opinions without interference
and to seek, receive and impart information and ideas througt
any media and regardless of frontiers."
Article 19 of "Universal Declaration of Human Rights"

Welcome to VX Heavens! This site is dedicated to providing information about computer viruses (or virii, as some would prefer) to anyone who is interested in this topic.

Frequently Asked Questions About Visual C++ .NET

64-bit Support
C++ and .NET
Visual C++ 2005
Devices
General
High-Performance Computing
IDE
ISO Conformance
Language
Libraries
MFC
Visual Studio Versions and Upgrades


FAQ

Using Win32 calling conventions

When writing code for the Win32 platform, most developers don't pay attention to selecting a "calling convention", and in most cases it doesn't really matter much. But as systems get larger and split into more modules (especially when third-party modules are to be included), this becomes something that cannot really be ignored.

In this Tech Tip, we discuss what the MSVC calling conventions are, why to choose one over the other, and "big system" considerations that may not be obvious.

Calling Conventions

The Windows Driver Developer's Digest

STUPID.SYS sample driver -- the minimal WDF driver used to illustrate Walter Oney's summary article on Windows Driver Framework

SAMPLE.SYS -- the minimal kernel DLL used to illustrate Tim Robert's article on kernel-mode DLL

PASSTHRU.SYS -- Tom Divine's augmented version of the DDK sample of the same name

WINBUILD.ZIP -- James Antognini's example of driver building

Sample Code

Linux Virtual Server

Virtual server is a highly scalable and highly available server built on a cluster of real servers. The architecture of server cluster is fully transparent to end users, and the users interact with the system as if it were only a single high-performance virtual server.

LVS

Lustre CFS

Cluster File Systems, Inc. is the leading developer of next generation technology for scalable high-performance file systems. Our Lustre® file system redefines scalability and has been designed from the ground up to meet the demands of the world's largest high-performance computer clusters.

Lustre has been designed from the ground up to feature the highest levels of:

reliability : Lustre features production-quality stability and failover, with zero single points of failure. More than 100 teraflops worldwide are deployed in production environments using Lustre to manage their data.

scalability : Lustre is used on several of the world's largest supercomputers -- including the world #1 BlueGene/L, and tens of others on the most recent Top500 listing.

performance : Metadata and I/O performance rates which are second to none, with your choice of hardware.

management : Aggregate your petabytes of storage into a single group- or enterprise-wide file system.

flexibility : Lustre's software solutions mean an end to proprietary hardware and vendor lock-ins.

Lustre CFS

Intel® C++ Compiler for Windows

Product Features

Intel® C++ Compiler for Windows* helps software run at top speed and features compatibility with the tools that developers use. This compiler fully supports multi-core processors along with existing Intel® processors and architectures. Advanced optimization features deliver outstanding application performance on the latest Intel processors.


Intel® C++ Compiler for Windows

How to Write a Windows XP Driver

Summary: This document describes the steps you should take to create a Microsoft® Windows® XP driver for your device. To create a Windows XP device driver:

Install the current Windows DDK. Read the system requirements and installation instructions in the stand-alone Getting Started HTML file supplied with the DDK.

Read Getting Started with Windows Drivers. This document guides you through the planning and decision-making process involved in making a Windows device driver from design through distribution. You should also look through the DDK documentation for device-type-specific information.

How to Write a Windows XP Driver

Templates and Generics

Insomnia and being a workaholic is an interesting combination. It is amazing how much work can be accomplished in the eight hours before everyone else comes to work. J

Anyways, I spent some time working on specifying generics in C++ yesterday so I figured I'd write about that today. Perhaps the most important message regarding generics is that they are not templates. That is evident in the C++ language design as it supports both generics and templates. At the PDC, I heard comments such as "generics are templates done right". This, sadly, is a misinformed opinion that too many people share



Templates and Generics

1394 Node-Targeted Asynchronous Transfers

To understand Windows 1394 asynchronous transfer operation, one must understand the different types of addressing modes that the Windows 1394 bus driver uses. Addressing modes determine how the bus driver interprets destination address information that is passed along with asynchronous transfer requests. For Windows 2000 and earlier platforms, there were two modes of addressing when using asynchronous transfers normal-mode and raw-mode. What these modes are and how they work is explained later. For XP and later platforms, there is a new addressing mode called virtual-mode addressing. Virtual-mode addressing is used for 1394 virtual devices. The virtual device mechanism for 1394 was introduced with the Windows XP 1394 bus driver stack. In order to fully understand 1394 asynchronous communication on Windows platforms, it is helpful to understand what 1394 virtual devices are and how they are used. In a moment, I will take a step to the side and cover virtual devices in some detail. As for asynchronous transfer addressing modes, none of these were documented in the Windows Device Driver Development Kit (DDK) help until about a year ago. Even now the documentation does not explain how one goes about implementing some of these modes. The following paragraphs will attempt to explain asynchronous addressing modes, and show some code that demonstrates how to go about implementing the different modes in a WDM device driver. First, let us look at 1394 virtual devices. If you do not care about 1394 virtual devices or if you are already familiar with them, you can just skip down to the section titled Asynchronous Transfers.


1394

Memory Management 1

Introduction
I’m writing this tutorial in an attempt to help you to write a memory manager for your own OS. I assume that you’ve decided to try and write your own OS kernel, and that you’ve got past the “boot-and-print-a-message” stage. Congratulations – you’ve got further than most people.

A memory manager (that is, a physical memory manager) is one of the components at the lowest level of every operating system, and it is vital for the splitting-up of your computer’s memory. Note that there might be several memory managers in your kernel, each working at a different level. I’ll be explaining the lowest-level one here. The allocator here won’t work as a malloc() unless you’re happy with a 4096-byte granularity.

Tim Robinson · timothy.robinson@ic.ac.uk · http://www.themoebius.org.uk/

Bonafide