Rails 3 · ruby · Ruby On Rails

Naming conventions on Ruby & Ruby on Rails

Ruby Naming Conventions Local VariablesLowercase letter followed by other characters, naming convention states that it is better to use underscores rather than camelBack for multiple word names, e.g. mileage, variable_xyz Instance VariablesInstance variables are defined using the single “at” sign (@) followed by a name. It is suggested that a lowercase letter should be used… Continue reading Naming conventions on Ruby & Ruby on Rails

ruby · Ruby On Rails

Ruby on Rails Security Guide

Please refer the following for Ruby on Rails best practices on the security. CSRF and XSS are the most important ones:-   1) CSRF – https://selvaonrails.wordpress.com/2012/04/03/ruby-on-rails-security-csrf-3/ 2) XSS – https://selvaonrails.wordpress.com/2012/04/03/ruby-on-rails-security-xss-2/ 3) Protection flags on cookies – https://selvaonrails.wordpress.com/2012/04/03/ruby-on-rails-security-protection-flags-on-session-cookies/ 4) Filter parameter logging – https://selvaonrails.wordpress.com/2012/04/03/ruby-on-rails-security-filtering-parameter-logging/

ruby · Ruby On Rails

Ruby on Rails Security – Protection Flags on Session Cookies

Analysis: When an unsuspecting user visits the site, the JavaScript executes, stealing the ‘sessionId’ cookie and sending it to the malicious user. Using the victim’s session ID, the malicious user can hijack the victim’s session and perform actions on their behalf. Solution and Fix: Add the ‘HttpOnly’ flag to the Set-Cookie directive for the session… Continue reading Ruby on Rails Security – Protection Flags on Session Cookies

ruby · Ruby On Rails

TaskJungler for maintaining todo list

TaskJungler is a gem available for Ruby. TaskJuggler is a modern and powerful project management tool. Its new approach to project planning and tracking is far superior to the commonly used Gantt chart editing tools. TaskJuggler uses one or more text files to describe a project. The main project should be placed in a file with the… Continue reading TaskJungler for maintaining todo list