The Artima Developer Community
Sponsored Link

.NET Buzz Forum
Adding CAPTCHA to FlexWiki

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Jonathan Cogley

Posts: 56
Nickname: thycotic
Registered: Dec, 2004

Jonathan Cogley is the founder of Thycotic Software Ltd, a C# MVP and TDD evangelist.
Adding CAPTCHA to FlexWiki Posted: Jan 12, 2005 8:19 AM
Reply to this message Reply

This post originated from an RSS feed registered with .NET Buzz by Jonathan Cogley.
Original Post: Adding CAPTCHA to FlexWiki
Feed Title: Jonathan Cogley's Blog
Feed URL: http://www.asp.net/err404.htm?aspxerrorpath=/jcogley/Rss.aspx
Feed Description: C#, Test Driven Development, Remote Scripting, CShark! :)
Latest .NET Buzz Posts
Latest .NET Buzz Posts by Jonathan Cogley
Latest Posts From Jonathan Cogley's Blog

Advertisement

Blog spam sucks but being hosted on weblogs.asp.net doesn't leave a lot of options at the moment.  Blog spam could seen as a personal attack on your good nature and an attempt to mess with your small expression outlet to the rest of the world?  Wiki spam on the company wiki however, is outright war! :-)

Thanks to Jeff for pointing me towards Miguel Jimenez's Clearscreen SharpHIP HIP-CAPTCHA Control. (More on Captcha technology here).

Miguel's Captcha code takes the form of a custom WebControl which should make it very easy to integrate into most ASP.NET applications.  Add it to a form, simple validation and the post doesn't go through without the right Captcha response.

Problem:  Browsing the FlexWiki code base I realised that it doesn't really use the WebControl/Postback/Validation model.  The entire page is rendered by the DoPage method.  Does this strike anyone else as odd, since FlexWiki started as an internal Microsoft application?

Solution: My attempts at dynamically loading the control or placing it on the .aspx all failed since FlexWiki doesn't use a server side <form>.  Finally I gave up on the control and used the HIPCodeGenerator class directly.

  1. Follow Miguel's installation instructions in readme file of the 1.1 release (the readme isn't in 1.2) 
  2. Download my modified FlexWiki wikiedit.aspx code behind here.
    • Note the new AddHipCodeToPage and IsValidHipCode methods.
    • There are also some small changes to the processing of DoPage to ensure the Captcha is enforced.

 

Read: Adding CAPTCHA to FlexWiki

Topic: [Cool Tool] XML Visualizer for Visual Studio .NET 2003 Previous Topic   Next Topic Topic: Geek Notes 2005-01-08

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use