29 March 2010

Hardware accelerated network monitoring: NetFPGA

NetFPGA

During my third year at Télécom Bretagne, I worked on a project with two colleagues to develop an hardware accelerated network monitoring tool using a NetFPGA. This low-level project was very interesting and made me discover how to develop directly in hardware using a language called Verilog.

To let you discover this project, I pasted below the abstract of our final report.

Abstract

The growing use of the Internet, with services like YouTube, Dailymotion or Peer-to-Peer, raises the demand for larger bandwidths continuously. This and the technological evolution leads to traffic which is becoming more and more important. With the increasing bandwidth, the observation and control of the traffic also needs to be accomplished at a higher speed. This new challenge is being encountered by using hardware implementations of monitoring algorithms.

During our third-year project at Télécom Bretagne we worked on such a hardware implementation using a NetFPGA, a PCI board containing an FPGA and four Ethernet ports. Starting with a simple Ethernet hub that we added to the existing structure of the NetFPGA, we continued with the implementation of a detection of TCP SYN packets. In order to count these SYN packets, needed for the detection of SYN flooding attacks, we used a special stream mining algorithm to reduce the memory needed : the CMS algorithm.

More information

Everything we did about this project is available online on the Trac of our project. The final report is also available (in French, sorry).

No Comments yet »

14 December 2009

Django better than a CMS?

Django logo

I recently had to rewrite a website I’m maintaining for a very small business: Le fil à soi. They are 3 teacher who offer courses of chinese massage, qi gong and Gestalt therapy in Bordeaux, France. The requirements for the website are quite simple:

  • presentation of the place, the people, and contact information
  • pages for all courses sorted in categories
  • automatic management of courses dates display and RSS feed generation
  • simple backend to modify courses information (should be used by the teachers, although they don’t really like computers and prefer sending me an email…)

The version I wanted to replace was a hand-made PHP website. I started it years ago when I knew little about websites technical design, so it had become really messy and complicated to maintain. I considered letting someone else maintain the website, so I needed a cleaner version.

Using a CMS: Drupal or WordPress

A CMS (Content Management System) is a platform that makes building a website easy. WordPress is particularly intended to create blogs, but there are plenty of plugins that enable to create any type of websites. Drupal is really made to build websites of any type. There are plenty of plugins too that address about every possible needs (calendar, online shop…)

The strength of these CMSs is that they manage the two parts of the website: the user part, and the administration part. The administration part gives you many simple ways to personalize and watch the user part.

I started two small prototypes using these CMSs and came to the same conclusion: none of them perfectly addresses my very simple needs.

For example for the courses dates managment: plenty of plugins do something close enough to what I want, but none do it exactly. So I will have to personnalize a plugin, probably without real documentation of the code. This plugin will then be updated (without documentation again) by its author, and I’ll have to maintain my changes again and again…

It’s the same for the theme: plenty of themes are available but I can’t seriously download and use a design without customizing it.

So I can make my very simple website using a CMS but:

  • the result will be huge, with plenty of features I won’t use (no blog, no users management needed…)
  • it will be difficult to maintain, and I will have to watch updates to the plugins I have customized
  • I will have to make regular updates when the CMS is updated, because known security flows of well-known CMSs are rapidly used by “hackers”

This is a lot of work for such a small website.

Using Django

Django isn’t really a CMS. It’s a Python framework to build websites (comparable to PHP Zend, Ruby On Rails…). So it means that you have to actually write code to use it.

The huge difference with other web frameworks is that Django has originally be developped for a news website, so content management was very important. That’s why an impressive feature is available: an automatic administration generation.

I just had to define my models (what a course is, what a teacher is, what a date, a category is). Then it was mapped to my database and the administration part was generated. I finally defined my views, that is to say the way these models are displayed to the users (with simple tools to generate RSS feeds, sitemaps…)

The advantages of this approach are:

  • the final application is very small, no useless features
  • you get exactly what you want, you haven’t to adapt to random plugins found on the Internet
  • you know perfectly what each line of code does (even if you don’t document it…)
  • the only updates you have to watch are Python and Django updates, that are rare and usually well managed

The only possible drawbacks I see:

  • There are much fewer people who are used to Python Django than people who are used to WordPress, so it will be more difficult to find maintainers (but they will be better :p)
  • Python has to be properly supported by you host. I use OVH, that supports Django only in CGI, but it’s okay for such a small website.
  • There is no WYSIWYG editor by default in Django-generated administration: this can be bad to edit articles (or courses descriptions for me). But it’s fairly easy to add TinyMCE as it’s purely javascript.

Conclusion

If you want to create a simple full-featured blog, use WordPress. If you want complicated features like an online shop, use Drupal.

But if you want to build a simple, dynamic and easy to maintain website, and coding doesn’t scare you too much, use Python Django. You will get exactly what you want, without much efforts, and the result will be very easy to maintain.

Le fil à soi website main page

Le fil à soi website main page

Le fil à soi pages administration

Le fil à soi pages administration

3 Comments »

10 June 2008

My UWA widgets

[lang_fr]Widgets UWA : write once, run everywhere[/lang_fr][lang_en]UWA widgets: write once, run everywhere[/lang_en]

I am yet migrating to this blog all the projects I maintain. As part of this process, I just migrated all the UWA widgets I created.

UWA widgets are tiny web applications that can run on platforms like Netvibes, IGoogle, Live.com, Opera, the Vista sidebar or the Apple dashboard.

I describe all these widgets in the category "UWA widgets".

Don’t hesitate to try these widgets, and please tell me in the comments on the page about the widget if you encounter problems.

No Comments yet »

  • Welcome!

    I write on this blog about my projects, my practices and my discoveries in the domains of the internet, networks and computer science.

    Tristan, French student in TELECOM Bretagne, a "grande école" specialized in telecommunications

    Contact me Twitter Facebook

    Read more »