Upgrade gems to latest revisions, fix Rails security vulnerability