Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Building Web Service Security
branch: master

Fix regression caused by #20

Object#present? is a monkey patch added by rails, and is often not
available in pure-ruby projects. Very surprised that this wasn't
covered by any of the existing tests.
latest commit 5223d3d475
Tim Jarratt authored

Akami Build Status

Building Web Service Security.


Akami is available through Rubygems and can be installed via:

$ gem install akami

Getting started

wsse = Akami.wsse

Set the credentials for wsse:UsernameToken basic auth:

wsse.credentials "username", "password"

Set the credentials for wsse:UsernameToken digest auth:

wsse.credentials "username", "password", :digest

Enable wsu:Timestamp headers. wsu:Created is automatically set to and wsu:Expires is set to + 60:

wsse.timestamp = true

Manually specify the values for wsu:Created and wsu:Expires:

wsse.created_at =
wsse.expires_at = + 60

Akami is based on an autovivificating Hash. So if you need to add custom tags, you can add them.

wsse["wsse:Security"]["wsse:UsernameToken"] = { "Organization" => "ACME" }

When generating the XML for the request, this Hash will be merged with another Hash containing all the default tags and values.
This way you might digg into some code, but then you can even overwrite the default values.

Something went wrong with that request. Please try again.