Saturday, March 29, 2008

I will be attending VS live this week in San Francisco.  Is any one else?

posted by Aaron Fischer on Saturday, March 29, 2008 3:37:21 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Friday, March 21, 2008

Something strange happened to Visual Studio 2008 after I installed Silverlight 2 beta tool kit.  It got slower, but the UI has changed.  I now see two scroll bars where the far left sometimes popes up a postit not type window telling me I have dead code. There is a little green/red icon in the far right corner indicating a success/failed build.  There is some type of color coded navigation under the vertical scroll bar.

posted by Aaron Fischer on Friday, March 21, 2008 8:34:41 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Wednesday, March 05, 2008

SQL Server Data Services this looks to be Microsoft's answer to Amazons Simple DB it sounds promising. 

SQL Server Data Services FAQ

posted by Aaron Fischer on Wednesday, March 05, 2008 1:55:39 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Tuesday, March 04, 2008

Rather then spend another 10+ hours on hold with HP tech support to have them replace my video card for the fourth time.  I replaced my latest ASUS 7600 card(bad fan)

ASUS7600

with an ASUS 8600 fanless/silent model.  As a side benefit I can now use the Nvidia control panel to rotate my monitors.

ASUS8600

posted by Aaron Fischer on Tuesday, March 04, 2008 8:39:00 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Monday, March 03, 2008

Here's a tool form Microsoft I never knew about but find very useful now Debug Diagnostic Tool. Version one was part of IIS Diagnostic toolkit but version 1.1 is a standalone tool

Generating Memory Dumps
When using DebugDiag, you need to first identify what kind of issue you are troubleshooting (e.g. a crash, hang, slow performance, or memory and handle usage). This step will aid in configuring the tool appropriately to get the right data, and therefore identifying the root cause of the problem and resolving it.
Process Crashes
A process crash is usually indicative of an unhandled exception occurring in a process or code running in a process that actively terminates the process. To debug a process crash, start by creating a crash rule against the process(s) in question. Similar to previous debuggers, DebugDiag will attach to a specific process (s) and will monitor the process for multiple types of exceptions or any custom breakpoints that cause the process(s) to terminate unexpectedly. When the crash occurs, a full memory dump file will be created, in the directory specified when setting up the crash rule.
Process Hangs or Slow Performance
To debug a process hang, use one of the following:
1- Create a hang rule. (this feature is available only for IIS processes) . The hang monitoring feature for IIS processes is designed to troubleshoot performance issues when users browse to pages in a web application and the pages take a long time to respond, or do not respond at all. During the hang rule creation wizard, specify the target processes to dump and a URL to be monitored along with a “Ping” interval and a response “timeout” The tools will send a request to the server at the configured intervals, and if the server does not respond before the configured timeout, a memory dump will be generated for the processes specified process(es).
2- Create a manual memory dump during the slow or hang state by right-clicking the process name in the processes view and choosing the “Create Full Userdump” option.
Memory or Handle Usage
To debug memory and handle usage, use one of the following:
1. Create a leak rule against the process in question. The leak monitoring feature will track memory allocations inside the process. Tracking is implemented by injecting a DLL (leaktrack.dll) into the specified process and monitoring memory allocations over time. When configuring a memory and handle leak rule, you can specify memory dump generation based on time or memory usage.
2. Using the “processes” view, right-click the process in question and select the “monitor for leaks” option. When the process has grown to the suspected problem size, manually dump the process by right-clicking on the same process in the processes view and choosing the “Create Full Userdump” option.
Analyzing Memory Dumps:
One of the most powerful features of the DebugDiag is the ability to analyze memory dumps and generate a report file showing the analysis, along with recommendations to resolve identified problems.
DebugDiag uses “Analysis Scripts” to analyze the process dump. 2 main analysis scripts are shipped with the tool:
Crash/Hang Analyzers
The crash/hang analysis script analyzes exception information in the dump for crashes if detected and analyzes known hang causes such as critical section related activity. This script includes IIS, MDAC, COM+ and Windows Socket information relevant to the process.
Memory Pressure Analyzers
The memory pressure analysis script analyzes the memory usage of the process and presents data gathered from the leak monitoring tool, when injected.

posted by Aaron Fischer on Monday, March 03, 2008 8:03:35 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Thursday, February 21, 2008

When I woke up this morning I had a vb webservice that was convinced it needed an app.manifest file.  When I attempted to build the project I would receive

Error    120    Error embedding Win32 manifest: Manifest File 'c:\Development\\My Project\app.manifest' cannot be found.    ProjectName.

After my Google searches turned up no love, I performed an indepth inspection of the ProjectName.vbproj file.  Some how an ApplicationManifest node was added to the PropertyGroup node.  After removing the <ApplicationManifest>My Project\app.manifest</ApplicationManifest> node I was once again able to build my web service project.

posted by Aaron Fischer on Thursday, February 21, 2008 11:36:11 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Tuesday, February 19, 2008

"Online Fraud Threats Show Constant Evolution" provides the perfect example of why you can't regulate software security solutions. The criminals adapt (we are dealing with professionals now.

RSA observes that emerging threats, multi-channel fraud and exploitation of unprotected applications are among the latest patterns and trends this year.

Further more this software has become a business, complete with software subscription plans.

Crimeware is also on the rise—apparently so much so that crimeware developers are even offering upgrade packages to buyers in the fraudster underground. When crimeware becomes detectable by anti-virus providers, developers will deliver a new ‘undetectable’ variant at a minimal cost, the report said.

  And our banks response is to implement Wish-It-Was Two-Factor.  Even legitimate Multi factor Authentications is at risk,

A German-speaking hacker crew is looting commercial bank accounts in four countries using a custom-built Trojan put in place by expertly crafted and extremely focused phishing attacks, a security researcher said today.

The malware's most distinguishing feature, said Don Jackson, a senior security researcher at SecureWorks Inc., is its ability to mimic the steps the human account owner would take to move money  Sophisticated Trojan loots business bank accounts

The best thing the Government can do is regulate a mandatory disclosure policy of all exploits.  This should drive the market in the correct direction.

posted by Aaron Fischer on Tuesday, February 19, 2008 7:57:20 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]

I have noticed that Flash Player is not working any longer in Internet explorer 7 after my installation of Vista SP1.  Flash player works fine in Firefox.  Any one else notice this?  Reinstalling flash does not work.  This appears to be the same issue Vista had when it first shipped.

Update.

Adobe released a new version of their Adobe Flash Player version 9.0.124.0 after installing this version Flash once again works for me.

posted by Aaron Fischer on Tuesday, February 19, 2008 7:36:17 AM (Pacific Standard Time, UTC-08:00)   #    Comments [4]
 Thursday, February 14, 2008

In .n1.1 a mixed mode MFC 7 application could register for the System::AppDomain::CurrentDomain::UnhandledException event and receive notice of an unhandled exception.  This worked well for logging exceptions ( except a few rare cases were the frame work was dead).  However in .net 2.0 this has changed, according to the new documentation

In the .NET Framework versions 1.0 and 1.1, an unhandled exception that occurred in a thread other than the main application thread was caught by the runtime and therefore did not cause the application to terminate. Thus, it was possible for the UnhandledException event to be raised without the application terminating. In the .NET Framework version 2.0, this backstop for unhandled exceptions in child threads was removed, because the cumulative effect of such silent failures included performance degradation, corrupted data, and lockups, all of which were difficult to debug. For more information, see Exceptions in Managed Threads.

To register an event handler for this event, you must have the required permissions, or a SecurityException is thrown.

Pasted from <http://msdn2.microsoft.com/en-us/library/system.appdomain.unhandledexception(VS.80).aspx>

So rather then being able to log errors with a detailed stack trace we are left with a GPF error message. 

We can overload the WinAPP::Run function and insert a try catch block, but exception we catch will always be the same System.Runtime.InteropServices.SEHException.  Optimistically I opened a Ticket with Microsoft for a recommend way to intercept the real exception details or  find a work around to enable the  UnhandledException event.  Microsoft's response was use a try catch block.  This is not a realistic answer.  There are cases were nullreferance exceptions are raised from unmanaged code.  And as much as I would like to wrap every method in a try catch statement, some how this doesn't sound like a good idea.

My best alternative is to is to register for the win32 SetUnhandledExceptionFilter and allow for the creation of a minidump.  For this I found a nice little library clrdump.

As an aside I find it interesting that the best articles for structured exception handling are from an August 1998 Bugslayer article and January 1997

A Crash Course on the Depths of Win32™ Structured Exception Handling both from the The Microsoft Systems Journal.

posted by Aaron Fischer on Thursday, February 14, 2008 2:48:37 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Tuesday, January 29, 2008

Sara published a Did you know that i have been looking for for ever how do I customize those toolbars with the functions I deem worthy.

Did you know... you can switch and swap buttons on the toolbars while the Tools - Customize dialog is showing - #139

Thanks for a great tip!

posted by Aaron Fischer on Tuesday, January 29, 2008 9:17:25 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]