| Code Name ^ | Language ^ | Type ^ | Author ^ | Date Added ^ |
|---|---|---|---|---|
| addBadIp | VBScript | Function | Will Perry | 2/4/2006 |
| Add a table to your Database called tblBadIp. Field1 - [IPAddress]VarChar(15) Primary Index, Field2 - [HitCount]Integer. When someone does something you don't like on your site this will add them to the list or increment the count of offenses | ||||
| addComma | VBScript | Function | Will Perry | 2/2/2006 |
| Formats an integer with commas every three digits | ||||
| altColor | VBScript | Function | Will Perry | 2/4/2006 |
| Each time the function is called alternates between returning the two values. Useful for alternating colors in a table. | ||||
| ASCII List | ASP | Script | Will Perry | 2/2/2006 |
| Generates a list of ASCII codes with their respective characters | ||||
| botTrap.asp | VBScript | Script | Will Perry | 2/27/2006 |
| Give this script a tempting name for bots like contacts.asp and set it to be excluded from your robots.txt. You may also want to place a hidden link to this in your website somewhere. I log each vialation and use my checkBannedIp function to lock out ip's with more than 5 violations. I then redirect the bot to a secondary trap. I like to use a script from Project Honeypot as the secondary trap. (http://www.projecthoneypot.org) The table in the database (tblBadIp) has 2 fields IPAddress {varchar(15)}, Hitcount {INT}. Sample Robots.txt (assumes you are name the script contacts.asp) User-agent: * Disallow:/contacts.asp | ||||
| buildMenu | ASP | Function | Will Perry | 2/2/2006 |
| Generates a menu item for a navigation menu Links go bold onhover and the current page link is always bold | ||||
| buildSelect | VBScript | Function | Will Perry | 2/2/2006 |
| Builds a select inputbox from a dataset | ||||
| checkBadHeader | VBScript | function | Will Perry | 2/27/2006 |
| Put this function in an include or call it from each page in your site. If a connection comes in with one of the bad headers in your table with it's bad header list or one of the banned IPs their IP is added to the bad IP table with a hitcount of one. I also check the user's IP address from the bat IP table by badIP reject script and bounce users with more than 10 bad attempts. (See function checkBannedIp) In this case users that fail the test are redirected to a script generated by Project Honeypot to foil SpamBots. (http://www.projecthoneypot.org) | ||||
| checkBannedIp | VBScript | Function | Will Perry | 2/27/2006 |
| Checks against a table of bad IP addresses. If a user has 10 or more violations they are redirected to a harmpless page. If this is called from each page on your site it will prevent banned IPs from accessing any of your pages. Alternatively you could serve up a 403 error header or redirect them out of your site completely. I am currently redirecting them to a script created by Project Honeypot to trap SpamBots. (http://www.projecthoneypot.org) | ||||
| chkUprAndLwrCase | vbscript | function | Will Perry | 4/13/2010 |
| This function will check a string to make sure it contains both upper and lower case characters | ||||
| chkUrl | VBScript | Function | Will Perry | 2/2/2006 |
| Checks for http:// or https:// in front of link and adds it if it is missing | ||||
| CLImages | VBScript | Script | Will Perry | 9/28/2009 |
| WIP - Script to Download images from Craig's List... WIP | ||||
| clnFile | VBScript | Function | Will Perry | 2/4/2006 |
| Prevents travesing of a directory tree by using ".." to move above the allowed area. | ||||
| clnSql | VBScript | Function | Will Perry | 2/2/2006 |
| Removes semicolon from string, replaces with colon. Removes single quote and replaces with double-single quote which is stored properly. Calls formatSqlDate() which properly formats dates for SQL. | ||||
| Detectall Server Variables | ASP | Script | Will Perry | 2/2/2006 |
| Detects all request.servervariable values and displays in browser | ||||
| detectall.asp | ASP | Script | Rob Hartman | 2/4/2006 |
| Spits out all availabe items in the request.servervariables collection. Useful as a reference. | ||||
| escape | ASP | Script | Will Perry | 2/4/2006 |
| either escapes or un-escapes a string. I use this sometimes to pick apart the URL in a phishing e-mail. | ||||
| Escape/UnEscape | ASP | Script | Will Perry | 2/2/2006 |
| Enter a string and click escape or unescape to add or remove escape characters | ||||
| escp | VBScript | Function | Will Perry | 2/2/2006 |
| Check to see if a value is null to prevent errors using the escape function | ||||
| fmtDate | VBScript | Function | Will Perry | 2/4/2006 |
| Safe Date format function. Checks for a valid date before applying the formatdatetime function. | ||||
| fmtDate | VBScript | Function | Will Perry | 2/2/2006 |
| Checks for valid date before performing formatdatetime function on a string/date | ||||
| fmtText | VBScript | Function | Will Perry | 2/2/2006 |
|
Converts line breaks in a string to for html display |
||||
| formatSqlDate | VBScript | Function | Will Perry | 2/2/2006 |
| Formats a date for SQL | ||||
| isChecked | VBScript | Function | Will Perry | 2/2/2006 |
| If True returns " checked" otherwise returns an empty string use for auto checking checkboxes when pulling external data | ||||
| isInArray | VBScript | Function | Will Perry | 2/4/2006 |
| Checks to see if a string is in an array, also allows | ||||
| isInDataset | VBScript | Function | Will Perry | 2/2/2006 |
| Check to see if a value is in a specific column of a dataset | ||||
| isRadio | VBScript | Function | Will Perry | 2/2/2006 |
| Checks to values if equal returns " checked" otherwise returns "". Use to check radio button when pulling external data | ||||
| isSelected | VBScript | Function | Will Perry | 2/2/2006 |
| Checks to values if equal returns " selected" otherwise returns "". Use to specify default select box option when pulling external data | ||||
| iTunes Podcast Playcount Updater | English | VBScript | Will Perry | 6/1/2009 |
| This is a script to keep iTunes from unsubscribing to podcasts that you do not listen to regularly. To use, save the following text into a file with the extension "vbs" for example "KeepPodcasts.vbs". Then either put it in your task scheduler or run it regularly. | ||||
| KeyGen | VBScript | Script | Will Perry | 2/2/2006 |
| script to generate a psuedorandom password or key | ||||
| keygen.htm | Javascript | Script/HTML | Will Perry | 2/4/2006 |
| Client side key generator. Allows the user to select whether all ascii characters are allowed(many are not acceptible for passwords in most systems), only common characters (these will usually be accepted for passwords), or no symbols (uses upper and lower case letters and numbers only) | ||||
| LaunchThunderbird.vbs | VBScript | VBS File | Will Perry | 2/13/2006 |
| Script to download your Thunderbird address book from an FTP serverwhen you open TB and upload it again when you close TB. It also make a backup of the address book each time it uploads. | ||||
| makeKey | VBScript | Function | Will Perry | 2/2/2006 |
| Generates a psuedorandom key/password of the specified length | ||||
| MonthCalendar | ASP | Function | Will Perry | 2/2/2006 |
| Generates a calendar for a single month 'thisDate'. This is the calendar in the upper left corner of this site, but without the stylesheets | ||||
| mungeString | VBScript | Function | Will Perry | 2/5/2006 |
| Converts a string to ascii escape characters nnn: in order to defeat some bots e-mail harvesting attempts. | ||||
| PageThief | VBScript | Script | Will Perry | 2/2/2006 |
| Uses the MSXMLHTTP object to pull a webpage and place it into a string variable. | ||||
| pickIcon | ASP | Function | Will Perry | 2/4/2006 |
| Selects an icon for displaying a file link | ||||
| popWin | JScript | Function | Will Perry | 2/4/2006 |
| A simplified popup window function | ||||
| PwGen | VBScript | VBScript | Will Perry | 4/13/2010 |
| A script to generate a random 8 character password that contains upper and lower case letters, a number, and a special character/symbol. | ||||
| rss2list.htm | JavaScript | Page | Will Perry | 4/12/2006 |
| This page retrieves an rss page and spits out a list of links. It must be run from yourr local system and IE needs to be set to "Allow active content to run in files on My Computer" You then need to replace the values for strUrl and strTitle with those of your RSS feed. The last thing you may want to do is to change the settings under | ||||
