Radical Development

January 31, 2012
by Steven Swafford
Comments Off

Microsoft Enterprise Library: Data Access Application Block

For those of you who have been using the Enterprise Library from Microsoft then I tip my hat to you. I admit that I have not used this library for a number of years and in most cases the reason is because I have honestly not been in a position to do so. It is a long story so don’t ask. There are a number of reason why you should seriously consider the use of the Enterprise Library and I cannot think of any better reason than those provided directly from Microsoft. The goals of Enterprise Library are the following: …

Continue reading

November 20, 2011
by Steven Swafford
Comments Off

Secure Development Series: Input Validation

Many websites today collect data from the user community which includes but not limited to an email address, address, or even a phone number. The single golden rule everyone must follow is never trust the data input. In order to mitigate the risk to ensure that the data received and processed by your application is acceptable you must first define what data your application should accept, what its syntax should be and the minimum and maximum lengths. This information will allow you to define a set of “acceptable” values for every entry data point that is captured. Foundation of Security Authentication: Addresses the question: who are you? …

Continue reading

May 3, 2011
by Steven Swafford
Comments Off

Creating Charts With Microsoft Chart Controls

There is no shortage of charting controls for the Microsoft .NET framework and while many do a great job, they may be overkill and costly to any project. If you’re not familiar with the Microsoft Chart Controls then you may find that you’re in for a pleasant surprise for two reasons; They are free Quickly render charts Quick Walkthrough My purpose here is simple and to the point. I want to demonstrate just how easy it is to return a chart to the end user. In this case I will be using an XML data source rather than a database …

Continue reading

April 27, 2011
by Steven Swafford
Comments Off

Security Development Lifecycle: SQL Injection Attacks

In an earlier post titled Security Development Lifecycle: Introduction I begun introducing what the Security Development Lifecycle (SDL) represents and as I continue this series I will focus on the SDL model that Microsoft has so graciously provided to the community. Introduction In part 2 of this series I want to focus of SQL Injection and for those of you just getting started it is important to understand what a SQL Injection attack is. Here is what Microsoft has stated: SQL injection is an attack in which malicious code is inserted into strings that are later passed to an instance …

Continue reading

March 28, 2011
by Steven Swafford
Comments Off

Poor Man Backup Using Robocopy, 7Zip and DropBox

Rather than talking about how important data backups are I thought I would take the time to show you how you can use tools that are free or low cost to automate backups using Dropbox. If you don’t have a Dropbox account then I strongly urge you to grab on and why not since it free for the first 2Gb. By using Dropbox you can access your data from any device that has internet connectivity. However the purpose of this article is to show you just how easy it is to perform backups. Tools Robocopy: is a command-line directory replication …

Continue reading

February 27, 2011
by Steven Swafford
Comments Off

Upload To A FTP Server Using C#

To upload file we create two streams, one for the FTP connection and another for the file we are reading from local disk to upload. Create a FtpWebRequest object, set the FtpWebRequest.Method property to UploadFile and set the FtpWebRequest.Credentials property to our login information. We will use the file stream to write to then open the file to upload and stream its data, and finally read the data from the input stream and write it back to the request stream. Then call the method with the right parameters, and you’re set to go:

February 21, 2011
by Steven Swafford
12 Comments

N-Tier Architecture Example

In software engineering, multi-tier architecture (often referred to as n-tier architecture) is a client–server architecture in which the presentation, the application processing, and the data management are logically separate processes. For example, an application that uses middleware to service data requests between a user and a database employs multi-tier architecture. The most widespread use of multi-tier architecture is the three-tier architecture. N-tier application architecture provides a model for developers to create a flexible and reusable application. By breaking up an application into tiers, developers only have to modify or add a specific layer, rather than have to rewrite the entire …

Continue reading