Skip to content

Commit

Permalink
deploy: e180765
Browse files Browse the repository at this point in the history
  • Loading branch information
anakinj committed Oct 5, 2024
1 parent e384809 commit 383d178
Show file tree
Hide file tree
Showing 91 changed files with 35,325 additions and 58 deletions.
Empty file added .nojekyll
Empty file.
1,009 changes: 1,009 additions & 0 deletions JWT.html

Large diffs are not rendered by default.

372 changes: 372 additions & 0 deletions JWT/Base64.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,372 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>
Class: JWT::Base64

&mdash; Documentation by YARD 0.9.37

</title>

<link rel="stylesheet" href="../css/style.css" type="text/css" />

<link rel="stylesheet" href="../css/common.css" type="text/css" />

<script type="text/javascript">
pathId = "JWT::Base64";
relpath = '../';
</script>


<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>

<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>


</head>
<body>
<div class="nav_wrap">
<iframe id="nav" src="../class_list.html?1"></iframe>
<div id="resizer"></div>
</div>

<div id="main" tabindex="-1">
<div id="header">
<div id="menu">

<a href="../_index.html">Index (B)</a> &raquo;
<span class='title'><span class='object_link'><a href="../JWT.html" title="JWT (module)">JWT</a></span></span>
&raquo;
<span class="title">Base64</span>

</div>

<div id="search">

<a class="full_list_link" id="class_list_link"
href="../class_list.html">

<svg width="24" height="24">
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
</svg>
</a>

</div>
<div class="clear"></div>
</div>

<div id="content"><h1>Class: JWT::Base64


<span class="private note title">Private</span>
</h1>
<div class="box_info">

<dl>
<dt>Inherits:</dt>
<dd>
<span class="inheritName">Object</span>

<ul class="fullTree">
<li>Object</li>

<li class="next">JWT::Base64</li>

</ul>
<a href="#" class="inheritanceTree">show all</a>

</dd>
</dl>











<dl>
<dt>Defined in:</dt>
<dd>lib/jwt/base64.rb</dd>
</dl>

</div>

<h2>Overview</h2><div class="docstring">
<div class="discussion">
<p class="note private">
<strong>This class is part of a private API.</strong>
You should avoid using this class if possible, as it may be removed or be changed in the future.
</p>

<p>Base64 encoding and decoding</p>


</div>
</div>
<div class="tags">


</div>







<h2>
Class Method Summary
<small><a href="#" class="summary_toggle">collapse</a></small>
</h2>

<ul class="summary">

<li class="public ">
<span class="summary_signature">

<a href="#loose_urlsafe_decode64-class_method" title="loose_urlsafe_decode64 (class method)">.<strong>loose_urlsafe_decode64</strong>(str) &#x21d2; Object </a>



</span>






<span class="private note title">private</span>


<span class="summary_desc"><div class='inline'></div></span>

</li>


<li class="public ">
<span class="summary_signature">

<a href="#url_decode-class_method" title="url_decode (class method)">.<strong>url_decode</strong>(str) &#x21d2; Object </a>



</span>






<span class="private note title">private</span>


<span class="summary_desc"><div class='inline'>
<p>Decode a string with URL-safe Base64 complying with RFC 4648.</p>
</div></span>

</li>


<li class="public ">
<span class="summary_signature">

<a href="#url_encode-class_method" title="url_encode (class method)">.<strong>url_encode</strong>(str) &#x21d2; Object </a>



</span>






<span class="private note title">private</span>


<span class="summary_desc"><div class='inline'>
<p>Encode a string with URL-safe Base64 complying with RFC 4648 (not padded).</p>
</div></span>

</li>


</ul>




<div id="class_method_details" class="method_details_list">
<h2>Class Method Details</h2>


<div class="method_details first">
<h3 class="signature first" id="loose_urlsafe_decode64-class_method">

.<strong>loose_urlsafe_decode64</strong>(str) &#x21d2; <tt>Object</tt>





</h3><div class="docstring">
<div class="discussion">
<p class="note private">
<strong>This method is part of a private API.</strong>
You should avoid using this method if possible, as it may be removed or be changed in the future.
</p>


</div>
</div>
<div class="tags">


</div><table class="source_code">
<tr>
<td>
<pre class="lines">


30
31
32
33</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'lib/jwt/base64.rb', line 30</span>

<span class='kw'>def</span> <span class='id identifier rubyid_loose_urlsafe_decode64'>loose_urlsafe_decode64</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='rparen'>)</span>
<span class='id identifier rubyid_str'>str</span> <span class='op'>+=</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>=</span><span class='tstring_end'>&#39;</span></span> <span class='op'>*</span> <span class='lparen'>(</span><span class='int'>4</span> <span class='op'>-</span> <span class='id identifier rubyid_str'>str</span><span class='period'>.</span><span class='id identifier rubyid_length'>length</span><span class='period'>.</span><span class='id identifier rubyid_modulo'>modulo</span><span class='lparen'>(</span><span class='int'>4</span><span class='rparen'>)</span><span class='rparen'>)</span>
<span class='op'>::</span><span class='const'>Base64</span><span class='period'>.</span><span class='id identifier rubyid_decode64'>decode64</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='period'>.</span><span class='id identifier rubyid_tr'>tr</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>-_</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>+/</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span><span class='rparen'>)</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>

<div class="method_details ">
<h3 class="signature " id="url_decode-class_method">

.<strong>url_decode</strong>(str) &#x21d2; <tt>Object</tt>





</h3><div class="docstring">
<div class="discussion">
<p class="note private">
<strong>This method is part of a private API.</strong>
You should avoid using this method if possible, as it may be removed or be changed in the future.
</p>

<p>Decode a string with URL-safe Base64 complying with RFC 4648. Deprecated support for RFC 2045 remains for now. (“All line breaks or other characters not found in Table 1 must be ignored by decoding software”)</p>


</div>
</div>
<div class="tags">


</div><table class="source_code">
<tr>
<td>
<pre class="lines">


19
20
21
22
23
24
25
26
27
28</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'lib/jwt/base64.rb', line 19</span>

<span class='kw'>def</span> <span class='id identifier rubyid_url_decode'>url_decode</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='rparen'>)</span>
<span class='op'>::</span><span class='const'>Base64</span><span class='period'>.</span><span class='id identifier rubyid_urlsafe_decode64'>urlsafe_decode64</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='rparen'>)</span>
<span class='kw'>rescue</span> <span class='const'>ArgumentError</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_e'>e</span>
<span class='id identifier rubyid_raise'>raise</span> <span class='kw'>unless</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_message'>message</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>invalid base64</span><span class='tstring_end'>&#39;</span></span>
<span class='id identifier rubyid_raise'>raise</span> <span class='const'><span class='object_link'><a href="Base64DecodeError.html" title="JWT::Base64DecodeError (class)">Base64DecodeError</a></span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Invalid base64 encoding</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>if</span> <span class='const'><span class='object_link'><a href="../JWT.html" title="JWT (module)">JWT</a></span></span><span class='period'>.</span><span class='id identifier rubyid_configuration'><span class='object_link'><a href="Configuration.html#configuration-instance_method" title="JWT::Configuration#configuration (method)">configuration</a></span></span><span class='period'>.</span><span class='id identifier rubyid_strict_base64_decoding'><span class='object_link'><a href="Configuration/Container.html#strict_base64_decoding-instance_method" title="JWT::Configuration::Container#strict_base64_decoding (method)">strict_base64_decoding</a></span></span>

<span class='id identifier rubyid_loose_urlsafe_decode64'>loose_urlsafe_decode64</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_tap'>tap</span> <span class='kw'>do</span>
<span class='const'><span class='object_link'><a href="Deprecations.html" title="JWT::Deprecations (module)">Deprecations</a></span></span><span class='period'>.</span><span class='id identifier rubyid_warning'><span class='object_link'><a href="Deprecations.html#warning-class_method" title="JWT::Deprecations.warning (method)">warning</a></span></span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Invalid base64 input detected, could be because of invalid padding, trailing whitespaces or newline chars. Graceful handling of invalid input will be dropped in the next major version of ruby-jwt</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='label'>only_if_valid:</span> <span class='kw'>true</span><span class='rparen'>)</span>
<span class='kw'>end</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>

<div class="method_details ">
<h3 class="signature " id="url_encode-class_method">

.<strong>url_encode</strong>(str) &#x21d2; <tt>Object</tt>





</h3><div class="docstring">
<div class="discussion">
<p class="note private">
<strong>This method is part of a private API.</strong>
You should avoid using this method if possible, as it may be removed or be changed in the future.
</p>

<p>Encode a string with URL-safe Base64 complying with RFC 4648 (not padded).</p>


</div>
</div>
<div class="tags">


</div><table class="source_code">
<tr>
<td>
<pre class="lines">


12
13
14</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'lib/jwt/base64.rb', line 12</span>

<span class='kw'>def</span> <span class='id identifier rubyid_url_encode'>url_encode</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='rparen'>)</span>
<span class='op'>::</span><span class='const'>Base64</span><span class='period'>.</span><span class='id identifier rubyid_urlsafe_encode64'>urlsafe_encode64</span><span class='lparen'>(</span><span class='id identifier rubyid_str'>str</span><span class='comma'>,</span> <span class='label'>padding:</span> <span class='kw'>false</span><span class='rparen'>)</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>

</div>

</div>

<div id="footer">
Generated on Sat Oct 5 21:00:11 2024 by
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.37 (ruby-3.3.5).
</div>

</div>
</body>
</html>
Loading

0 comments on commit 383d178

Please sign in to comment.