aboutsummaryrefslogtreecommitdiffhomepage
path: root/Crypto-Macaroon.html
diff options
context:
space:
mode:
Diffstat (limited to 'Crypto-Macaroon.html')
-rw-r--r--Crypto-Macaroon.html5
1 files changed, 5 insertions, 0 deletions
diff --git a/Crypto-Macaroon.html b/Crypto-Macaroon.html
new file mode 100644
index 0000000..963fcaa
--- /dev/null
+++ b/Crypto-Macaroon.html
@@ -0,0 +1,5 @@
1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Crypto.Macaroon</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
2window.onload = function () {pageLoad();setSynopsis("mini_Crypto-Macaroon.html");};
3//]]>
4</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">hmacaroons-0.5.0.0: Haskell implementation of macaroons</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>(c) 2015 Julien Tanguy</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>julien.tanguy@jhome.fr</td></tr><tr><th>Stability</th><td>experimental</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell2010</td></tr></table><p class="caption">Crypto.Macaroon</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Types</a></li><li><a href="#g:2">Accessing functions</a><ul><li><a href="#g:3">Macaroons</a></li><li><a href="#g:4">Caveats</a></li></ul></li><li><a href="#g:5">Create Macaroons</a></li><li><a href="#g:6">Serialize</a></li><li><a href="#g:7">Verify</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Pure haskell implementations of macaroons.</p><p>Warning: this implementation has not been audited by security experts.
5Do not use in production</p><p>References:</p><ul><li>Macaroons: Cookies with Contextual Caveats for Decentralized Authorization in the Cloud <a href="http://research.google.com/pubs/pub41892.html">http://research.google.com/pubs/pub41892.html</a></li><li>Time for better security in NoSQL <a href="http://hackingdistributed.com/2014/11/23/macaroons-in-hyperdex">http://hackingdistributed.com/2014/11/23/macaroons-in-hyperdex</a></li></ul></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:Macaroon">Macaroon</a></li><li class="src short"><span class="keyword">data</span> <a href="#t:Caveat">Caveat</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:Secret">Secret</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:Key">Key</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:Location">Location</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:Sig">Sig</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></li><li class="src short"><a href="#v:location">location</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a></li><li class="src short"><a href="#v:identifier">identifier</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></li><li class="src short"><a href="#v:caveats">caveats</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; [<a href="Crypto-Macaroon.html#t:Caveat">Caveat</a>]</li><li class="src short"><a href="#v:signature">signature</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Sig">Sig</a></li><li class="src short"><a href="#v:cl">cl</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a></li><li class="src short"><a href="#v:cid">cid</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></li><li class="src short"><a href="#v:vid">vid</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></li><li class="src short"><a href="#v:create">create</a> :: <a href="Crypto-Macaroon.html#t:Secret">Secret</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></li><li class="src short"><a href="#v:inspect">inspect</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:addFirstPartyCaveat">addFirstPartyCaveat</a> :: <a href="Crypto-Macaroon.html#t:Key">Key</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></li><li class="src short">module <a href="Crypto-Macaroon-Serializer-Base64.html">Crypto.Macaroon.Serializer.Base64</a></li><li class="src short">module <a href="Crypto-Macaroon-Verifier.html">Crypto.Macaroon.Verifier</a></li></ul></div><div id="interface"><h1 id="g:1">Types</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Macaroon" class="def">Macaroon</a></p><div class="doc"><p>Main structure of a macaroon</p></div><div class="subs instances"><p id="control.i:Macaroon" class="caption collapser" onclick="toggleSection('i:Macaroon')">Instances</p><div id="section.i:Macaroon" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></span></td><td class="doc"><p>Constant-time Eq instance</p></td></tr><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Text-Show.html#t:Show">Show</a> <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></span></td><td class="doc"><p>show instance conforming to the <code>inspect</code> &quot;specification&quot;</p></td></tr><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/deepseq-1.4.1.1/Control-DeepSeq.html#t:NFData">NFData</a> <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></span></td><td class="doc"><p>NFData instance for use in the benchmark</p></td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Caveat" class="def">Caveat</a></p><div class="doc"><p>Caveat structure</p></div><div class="subs instances"><p id="control.i:Caveat" class="caption collapser" onclick="toggleSection('i:Caveat')">Instances</p><div id="section.i:Caveat" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a></span></td><td class="doc"><p>Constant-time Eq instance</p></td></tr><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Text-Show.html#t:Show">Show</a> <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a></span></td><td class="doc"><p>show instance conforming to the <code>inspect</code> &quot;specification&quot;</p></td></tr><tr><td class="src clearfix"><span class="inst-left"><a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/deepseq-1.4.1.1/Control-DeepSeq.html#t:NFData">NFData</a> <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a></span></td><td class="doc"><p>NFData instance for use in the benchmark</p></td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Secret" class="def">Secret</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></p><div class="doc"><p>Type alias for Macaroons secret keys</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Key" class="def">Key</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></p><div class="doc"><p>Type alias for Macaroons and Caveat and identifiers</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Location" class="def">Location</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></p><div class="doc"><p>Type alias for Macaroons and Caveat locations</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Sig" class="def">Sig</a> = <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/bytestring-0.10.6.0/Data-ByteString.html#t:ByteString">ByteString</a></p><div class="doc"><p>Type alias for Macaroons signatures</p></div></div><h1 id="g:2">Accessing functions</h1><h2 id="g:3">Macaroons</h2><div class="top"><p class="src"><a name="v:location" class="def">location</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a></p><div class="doc"><p>Target location</p></div></div><div class="top"><p class="src"><a name="v:identifier" class="def">identifier</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></p><div class="doc"><p>Macaroon Identifier</p></div></div><div class="top"><p class="src"><a name="v:caveats" class="def">caveats</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; [<a href="Crypto-Macaroon.html#t:Caveat">Caveat</a>]</p><div class="doc"><p>List of caveats</p></div></div><div class="top"><p class="src"><a name="v:signature" class="def">signature</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Sig">Sig</a></p><div class="doc"><p>Macaroon HMAC signature</p></div></div><h2 id="g:4">Caveats</h2><div class="top"><p class="src"><a name="v:cl" class="def">cl</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a></p><div class="doc"><p>Caveat target location</p></div></div><div class="top"><p class="src"><a name="v:cid" class="def">cid</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></p><div class="doc"><p>Caveat identifier</p></div></div><div class="top"><p class="src"><a name="v:vid" class="def">vid</a> :: <a href="Crypto-Macaroon.html#t:Caveat">Caveat</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a></p><div class="doc"><p>Caveat verification key identifier</p></div></div><h1 id="g:5">Create Macaroons</h1><div class="top"><p class="src"><a name="v:create" class="def">create</a> :: <a href="Crypto-Macaroon.html#t:Secret">Secret</a> -&gt; <a href="Crypto-Macaroon.html#t:Key">Key</a> -&gt; <a href="Crypto-Macaroon.html#t:Location">Location</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></p><div class="doc"><p>Create a Macaroon from its key, identifier and location</p></div></div><div class="top"><p class="src"><a name="v:inspect" class="def">inspect</a> :: <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="file:///opt/ghc/7.10.2/share/doc/ghc/html/libraries/base-4.8.1.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Inspect a macaroon's contents. For debugging purposes.</p></div></div><div class="top"><p class="src"><a name="v:addFirstPartyCaveat" class="def">addFirstPartyCaveat</a> :: <a href="Crypto-Macaroon.html#t:Key">Key</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a> -&gt; <a href="Crypto-Macaroon.html#t:Macaroon">Macaroon</a></p><div class="doc"><p>Add a first party Caveat to a Macaroon, with its identifier</p></div></div><h1 id="g:6">Serialize</h1><div class="top"><p class="src">module <a href="Crypto-Macaroon-Serializer-Base64.html">Crypto.Macaroon.Serializer.Base64</a></p></div><h1 id="g:7">Verify</h1><div class="top"><p class="src">module <a href="Crypto-Macaroon-Verifier.html">Crypto.Macaroon.Verifier</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.1</p></div></body></html> \ No newline at end of file