Sha256: c17ff962fc25e1d27e49d174c5f256a7c58feaed8bd84d8804b06c3666e05f2a
Contents?: true
Size: 985 Bytes
Versions: 1
Compression:
Stored size: 985 Bytes
Contents
# UrlSign Quickly generate and verify signed urls. ## Installation Add this line to your application's Gemfile: ```ruby gem 'url_signer' ``` And then execute: $ bundle Or install it yourself as: $ gem install url_signer ## Usage ### URL signing To convert a URL into a signed url, pass it to `UrlSigner.sign`, passing it either a string of an instance of `URI`. ```ruby >>> signed_url = UrlSigner.sign('http://google.fr?q=test', key='mykey') ``` the returned value `signed_url` is an instance of `URI`. ### URL verification Given a signed URL, you can check its authenticity by calling `UrlSigner.valid?` on it: ```ruby >>> UrlSigner.valid?(signed_url) true ``` ## Contributing 1. Fork it ( https://github.com/[my-github-username]/url_sign/fork ) 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Add some feature'`) 4. Push to the branch (`git push origin my-new-feature`) 5. Create a new Pull Request
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
url_signer-0.1 | README.md |