<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jun 18, 2013 at 2:49 PM, Kris Borchers <span dir="ltr">&lt;<a href="mailto:kris@redhat.com" target="_blank">kris@redhat.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">This all makes sense to me. It is similar to what I was trying to do with JS but still not sure we will get it to work or not.</div>
</blockquote><div><br></div><div><br></div><div style>we were expecting that :) thanks for the feedback :) </div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word"><div><br></div><div>+1</div><div><div class="h5"><div><br><div><div>On Jun 18, 2013, at 5:01 AM, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt; wrote:</div>
<br><blockquote type="cite"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jun 18, 2013 at 11:53 AM, Christos Vasilakis <span dir="ltr">&lt;<a href="mailto:cvasilak@gmail.com" target="_blank">cvasilak@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><br><div><div><div>On Jun 18, 2013, at 12:33 PM, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt; wrote:</div>

<br><blockquote type="cite"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jun 18, 2013 at 11:26 AM, Christos Vasilakis <span dir="ltr">&lt;<a href="mailto:cvasilak@gmail.com" target="_blank">cvasilak@gmail.com</a>&gt;</span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word">Hi team,<div><div><br></div>

<div>we have decided for our ios 1.1.0 release to go with the approach of setting the NSURLCredential as a config param on the pipe.</div>
</div></div></blockquote><div><br></div><div><br></div><div>Not really decided, since decisions are made here, on the public mailing list :-) </div></div></div></div></blockquote><div><br></div></div><div>+1000 for that wrong expression my bad :(</div>

</div></div></blockquote><div><br></div><div><br></div><div>:-) all good! not a big deal </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">

<div><div><div><br></div><br><blockquote type="cite"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>As mentioned on the meeting notes we talked about it, coming to the conclusion, that for now, it makes more sense using this approach (compared to the AGAuthModule with login/logout/enroll).</div>


<div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div> That is:</div><div><br></div><div>
<pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px"><div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="margin:0px;padding:0px;border:0px;color:rgb(68,85,136);font-weight:bold">id</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">&lt;</span><span style="margin:0px;padding:0px;border:0px">AGPipe</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">&gt;</span> <span style="margin:0px;padding:0px;border:0px">pipe</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">=</span> <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">_pipeline</span> <span style="margin:0px;padding:0px;border:0px">pipe</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:^</span><span style="margin:0px;padding:0px;border:0px">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(68,85,136);font-weight:bold">id</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">&lt;</span><span style="margin:0px;padding:0px;border:0px">AGPipeConfig</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">&gt;</span> <span style="margin:0px;padding:0px;border:0px">config</span><span style="margin:0px;padding:0px;border:0px">)</span> <span style="margin:0px;padding:0px;border:0px">{</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">        <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">config</span> <span style="margin:0px;padding:0px;border:0px">setName</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:</span><span style="margin:0px;padding:0px;border:0px;color:rgb(221,17,68)">@&quot;autobots&quot;</span><span style="margin:0px;padding:0px;border:0px">];</span></div>


</div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">        <span style="margin:0px;padding:0px;border:0px;color:rgb(153,153,136);font-style:italic">// set up credentials for Basic/Digest</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">        <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">config</span> <span style="margin:0px;padding:0px;border:0px">setCredential</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:</span><span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">NSURLCredential</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">                <span style="margin:0px;padding:0px;border:0px">credentialWithUser:</span><span style="margin:0px;padding:0px;border:0px">PASSING_USERNAME</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="white-space:pre-wrap">                </span><span style="margin:0px;padding:0px;border:0px">password</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:</span><span style="margin:0px;padding:0px;border:0px">LOGIN_PASSWORD</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="white-space:pre-wrap">        </span>        <span style="margin:0px;padding:0px;border:0px">persistence</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:</span><span style="margin:0px;padding:0px;border:0px">NSURLCredentialPersistenceNone</span><span style="margin:0px;padding:0px;border:0px">]];</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">    <span style="margin:0px;padding:0px;border:0px">}];</span></div>


<div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="margin:0px;padding:0px;border:0px"><br>


</span></div></pre></div></div></blockquote><div><br></div><div>I do like it - it&#39;s clean!</div><div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div style="word-wrap:break-word"><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px"><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="margin:0px;padding:0px;border:0px"></span></div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="margin:0px;padding:0px;border:0px"><span style="font-family:Helvetica;font-size:medium;line-height:normal;white-space:normal"><br></span></span></div><div style="margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="color:rgb(51,51,51);font-family:Helvetica;font-size:12px;line-height:18px;white-space:normal">Main point that we decided to go with that approach is that users are </span><span style="color:rgb(51,51,51);font-family:Helvetica;font-size:12px;line-height:18px;white-space:normal">familiar</span><font color="#333333" face="Helvetica"><span style="line-height:18px;white-space:normal"> with the NSURLCredential object and is more straightforward to use instead of going through the authentication module &#39;login&#39;, &#39;logout&#39; requests for this type of auth.  </span></font><span style="line-height:18px;color:rgb(51,51,51);white-space:normal;font-family:Helvetica">It&#39;s a similar approach on what our underlying networking lib </span><span style="line-height:18px;color:rgb(51,51,51);white-space:normal;font-family:Helvetica">does when the user wants to set the credentials. </span></div>


</pre></div></blockquote><div><br></div><div>Fully agree - and this reflects what we discussed on the iOS team meeting (this is the mentioned follow-up).</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div style="word-wrap:break-word"><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px"><div style="margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="line-height:18px;color:rgb(51,51,51);white-space:normal;font-family:Helvetica">A</span><font color="#333333" face="Helvetica"><span style="font-size:12px;line-height:18px;white-space:normal"> note would be added for the user to be cautious when setting the persistence type (e.g. </span></font><span style="color:rgb(102,102,102);font-size:13px;white-space:normal;font-family:Courier,Consolas,monospace">NSURLCredentialPersistencePermanent) </span><span><font color="#333333" face="Helvetica"><span style="line-height:18px;white-space:normal">so he can clear it up afterwards.  </span></font></span></div>


</pre></div></blockquote><div><br></div><div>Ah, yeah - that&#39;s perfect and good!</div><div><br></div><div>+1 on that</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div style="word-wrap:break-word"><div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px"><div style="margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="font-family:Helvetica;white-space:normal;color:rgb(51,51,51);font-size:12px;line-height:18px"><br>


</span></div><div style="margin:0px;padding:0px 0px 0px 10px;border:0px"><span style="font-family:Helvetica;white-space:normal;color:rgb(51,51,51);font-size:12px;line-height:18px">Thanks,</span></div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="font-family:Helvetica;white-space:normal">Christos</span></div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<span style="font-family:Helvetica;white-space:normal"><br></span></div><div style="color:rgb(51,51,51);font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;line-height:18px;margin:0px;padding:0px 0px 0px 10px;border:0px">


<br></div></pre></div><div><div><div>On Jun 3, 2013, at 4:32 PM, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt; wrote:</div><br><blockquote type="cite">
<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jun 3, 2013 at 3:22 PM, Christos Vasilakis <span dir="ltr">&lt;<a href="mailto:cvasilak@gmail.com" target="_blank">cvasilak@gmail.com</a>&gt;</span> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Hi<div><br></div><div>I guess we can have both approaches </div></div></blockquote><div>



<br></div><div>Not sure if we would mix a bit too much here</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">



<div>too and document the fact that care should be taken for the persistent type. </div><div><br></div><div>Further, another possible option allowing more more full control, is to expose as an option the underlying block that iOS provides so users can feed their own block.  It is similar to the approach the underlying afnetworking library does for users to <a href="https://github.com/AFNetworking/AFNetworking/blob/master/AFNetworking/AFURLConnectionOperation.h#L320" target="_blank">configure</a> if they wish too.</div>



<div><br></div><div>In essence, something similar to:</div><div><br></div><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font-size:12px;font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;color:rgb(51,51,51);line-height:18px">
<div style="margin:0px;padding:0px 0px 0px 10px;border:0px"> <span style="margin:0px;padding:0px;border:0px;color:rgb(68,85,136);font-weight:bold">id</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">&lt;</span><span style="margin:0px;padding:0px;border:0px">AGPipe</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">&gt;</span> <span style="margin:0px;padding:0px;border:0px">pipe</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">=</span> <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">_pipeline</span> <span style="margin:0px;padding:0px;border:0px">pipe</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:^</span><span style="margin:0px;padding:0px;border:0px">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(68,85,136);font-weight:bold">id</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">&lt;</span><span style="margin:0px;padding:0px;border:0px">AGPipeConfig</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">&gt;</span> <span style="margin:0px;padding:0px;border:0px">config</span><span style="margin:0px;padding:0px;border:0px">)</span> <span style="margin:0px;padding:0px;border:0px">{</span></div>



<div style="margin:0px;padding:0px 0px 0px 10px;border:0px">        <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">config</span> <span style="margin:0px;padding:0px;border:0px">setName</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:</span><span style="margin:0px;padding:0px;border:0px;color:rgb(221,17,68)">@&quot;autobots&quot;</span><span style="margin:0px;padding:0px;border:0px">];</span></div>



<div style="margin:0px;padding:0px 0px 0px 10px;border:0px">        <span style="margin:0px;padding:0px;border:0px;color:rgb(153,153,136);font-style:italic">// correct credentials</span></div><div style="margin:0px;padding:0px 0px 0px 10px;border:0px;background-color:rgb(255,255,204)">



        <span style="margin:0px;padding:0px;border:0px">[</span><span style="margin:0px;padding:0px;border:0px">config</span> <span style="color:rgb(153,0,0);font-weight:bold">setAuthenticationChallengeBlock</span><span style="margin:0px;padding:0px;border:0px;font-weight:bold">:^</span><span style="margin:0px;padding:0px;border:0px">(</span><span style="margin:0px;padding:0px;border:0px">NSURLConnection</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">*</span><span style="margin:0px;padding:0px;border:0px">connection</span><span style="margin:0px;padding:0px;border:0px">,</span> <span style="margin:0px;padding:0px;border:0px">NSURLAuthenticationChallenge</span> <span style="margin:0px;padding:0px;border:0px;font-weight:bold">*</span><span style="margin:0px;padding:0px;border:0px">challenge</span><span style="margin:0px;padding:0px;border:0px">) {</span></div>



<div style="margin:0px;padding:0px 0px 0px 10px;border:0px">                // create the credentials and server them to the challenge request  </div><div style="margin:0px;padding:0px 0px 0px 10px;border:0px">    <span style="margin:0px;padding:0px;border:0px">}];</span></div>



</pre><div><br></div><div>Wdyt?</div></div></blockquote><div><br></div><div>Not sure on that as well. Right now we configure initial state/params. Not sure we should really do extend the config to also accept &quot;blocks/functions&quot; to react on behaviour. Hrm... </div>



<div><br></div><div><br></div><div><br></div><div><br></div><div> </div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">



<span><font color="#888888"><div><br></div><div>Christos</div></font></span><div><div><br></div><div><br></div><div><div><div>On May 29, 2013, at 1:27 PM, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt; wrote:</div>



<blockquote type="cite"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, May 29, 2013 at 12:18 PM, Bruno Oliveira <span dir="ltr">&lt;<a href="mailto:bruno@abstractj.org" target="_blank">bruno@abstractj.org</a>&gt;</span> wrote:<br>





<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hi, sorry for my n00bish. I like the idea of libraries to make<br>






developer&#39;s life easier, I just have few questions.<br>
<br>
Is possible to have both into AGAuthenticationModuleAdapter?<br>
NSURLCredential for developers pretty familiar with it (and wants full<br>
control)  and HTTPBasicDigestAuthenticationModule for developer who want<br>
to keep it simple?<br></blockquote><div><br></div><div>Interesting point. Let me think about it</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">






<br>
Another question? Why not HTTPAuthenticationModule? With the addition of<br>
more auth schemes you will end with something like<br>
HTTPBasicDigestHawkPersonaOAuth2AuthenticationModule.<br></blockquote><div><br></div><div><br></div><div>oh, right :) yeah, let&#39;s name it AG<span style="font-family:arial,sans-serif;font-size:13px">HTTPAuthenticationModule.h/m. Good point</span></div>





<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div><br>
<br>
<br>
Corinne Krych wrote:<br>
&gt; Thanks for the clarification.<br>
&gt; I think I didn&#39;t get it.<br>
&gt; Indeed it should be well documented  as you would expect a login action<br>
&gt; (ie doing an actual login on endpoint) when sending a login message.<br>
&gt; saveLoginCredentials would be the correct message but I guess we rather<br>
&gt; stick to AGAuthenticationModuleAdapter protocol.<br>
&gt;<br>
&gt; +1<br>
&gt; Corinne<br>
&gt;<br>
&gt;<br>
&gt; On 29 May 2013 11:13, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a><br>
</div><div>&gt; &lt;mailto:<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt;&gt; wrote:<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;     On Wed, May 29, 2013 at 10:20 AM, Christos Vasilakis<br>
</div><div>&gt;     &lt;<a href="mailto:cvasilak@gmail.com" target="_blank">cvasilak@gmail.com</a> &lt;mailto:<a href="mailto:cvasilak@gmail.com" target="_blank">cvasilak@gmail.com</a>&gt;&gt; wrote:<br>
&gt;<br>
&gt;         Hi,<br>
&gt;<br>
&gt;         iOS platform provides built-in implementations for<br>
&gt;         authenticating against HTTP endpoints that support Basic /<br>
&gt;         Digest authentication (among others). The workflow when iOS<br>
&gt;         tries to authenticate against those endpoints is basically:<br>
&gt;<br>
&gt;         a) A credential storage singleton object<br>
</div>&gt;         &lt;<a href="https://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSURLCredentialStorage_Class/Reference/Reference.html" target="_blank">https://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSURLCredentialStorage_Class/Reference/Reference.html</a>&gt; provided<br>






<div>&gt;         by the system is consulted for authentication credentials. If<br>
&gt;         credentials are found, the system proceeds with authentication.<br>
&gt;         Understandably for this to work, the developer has to initially<br>
&gt;         push the credentials to the system object (and remove when done).<br>
&gt;<br>
&gt;         b) If credentials are NOT found, the system tries to call the<br>
&gt;         delegate method e.g.<br>
&gt;         &#39;connection:didReceiveAuthenticationChallenge<br>
</div>&gt;         &lt;<a href="http://developer.apple.com/library/mac/documentation/Foundation/Reference/NSURLConnectionDelegate_Protocol/Reference/Reference.html#//apple_ref/occ/intfm/NSURLConnectionDelegate/connection:didReceiveAuthenticationChallenge" target="_blank">http://developer.apple.com/library/mac/documentation/Foundation/Reference/NSURLConnectionDelegate_Protocol/Reference/Reference.html#//apple_ref/occ/intfm/NSURLConnectionDelegate/connection:didReceiveAuthenticationChallenge</a>:&gt;&#39;,<br>






<div>&gt;         giving a chance for the user to provide the credentials, by<br>
&gt;         calling the appropriate methods on the authentication challenge<br>
&gt;         object passed in.<br>
&gt;<br>
&gt;         AeroGear library,  currently has a notion of pluggable<br>
&gt;         authentication modules providing an interface for clients to<br>
&gt;         implement &#39;login&#39;, and &#39;logout&#39; methods, depending on the<br>
&gt;         authentication scenarios that they try to support. This fits<br>
&gt;         nicely with singleton credential storage approach, in the sense<br>
&gt;         when doing &#39;login&#39; and &#39;logout&#39;, we simply edit the credential<br>
&gt;         storage adding or removing credentials appropriately. A branch<br>
&gt;         for this work can be found here<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios/tree/basic.digest.auth" target="_blank">https://github.com/cvasilak/aerogear-ios/tree/basic.digest.auth</a>&gt;.<br>
<div>&gt;         For usage, have a look at our integration test<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.auth/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m" target="_blank">https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.auth/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m</a>&gt;<br>






<div>&gt;<br>
&gt;         For testing purposes, another branch<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios/tree/basic.digest.nsurlcredential" target="_blank">https://github.com/cvasilak/aerogear-ios/tree/basic.digest.nsurlcredential</a>&gt; was<br>
<div>&gt;         created, this time letting the user to directly pass<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.nsurlcredential/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m#L50" target="_blank">https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.nsurlcredential/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m#L50</a>&gt; an<br>






&gt;         NSURLCredential<br>
&gt;         &lt;<a href="http://developer.apple.com/library/ios/#Documentation/Cocoa/Reference/Foundation/Classes/NSURLCredential_Class/Reference/Reference.html" target="_blank">http://developer.apple.com/library/ios/#Documentation/Cocoa/Reference/Foundation/Classes/NSURLCredential_Class/Reference/Reference.html</a>&gt; object<br>






<div>&gt;         initialised with the username/password combination during the<br>
&gt;         Pipe configuration. Those credentials are internally stored and<br>
&gt;         given back to the system by implementing the necessary callback<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios/blob/basic.digest.nsurlcredential/AeroGear-iOS/AeroGear-iOS/core/AGHttpClient.m#L240" target="_blank">https://github.com/cvasilak/aerogear-ios/blob/basic.digest.nsurlcredential/AeroGear-iOS/AeroGear-iOS/core/AGHttpClient.m#L240</a>&gt;.<br>






<div>&gt;         A usage example can be found in our integration test<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.nsurlcredential/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m" target="_blank">https://github.com/cvasilak/aerogear-ios-integration/blob/basic.digest.nsurlcredential/AeroGear-iOS-Integration/AeroGear-iOS-IntegrationTests/AGHttpBasicAuthenticationTests.m</a>&gt;<br>






<div>&gt;<br>
&gt;         advantages of using the singleton approach:<br>
&gt;         - fits nicely with the authentication mechanism we have in place<br>
&gt;         (as an extension HTTPBasicDigestAuthenticationModule<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios/blob/basic.digest.auth/AeroGear-iOS/AeroGear-iOS/security/AGHttpBasicDigestAuthentication.m" target="_blank">https://github.com/cvasilak/aerogear-ios/blob/basic.digest.auth/AeroGear-iOS/AeroGear-iOS/security/AGHttpBasicDigestAuthentication.m</a>&gt;)<br>






<div>&gt;         so user familiarity when looking to add basic/digest support to<br>
&gt;         the Pipe.<br>
&gt;         - we control the credential type e.g.<br>
&gt;         &#39;NSURLCredentialPersistenceForSession&#39;. This eliminates errors<br>
&gt;         of using &#39;NSURLCredentialPersistencePermanent&#39; and having the<br>
&gt;         user to explicitly clear the keychain when trying to login with<br>
&gt;         a different combination. For my search, many errors occurs<br>
&gt;         because of this.<br>
&gt;<br>
&gt;         disadvantages of using the singleton approach:<br>
&gt;         - not sure if many iOS dev will like the fact of creating an<br>
&gt;         Authenticator object instead of using directly an<br>
&gt;         NSURLCredential object that are used to.<br>
&gt;<br>
&gt;         ---<br>
&gt;         advantages of using the &#39;nsurlcredential&#39; directly:<br>
&gt;         - users familiarity with the object.<br>
&gt;         - not explicit login logout request.<br>
&gt;<br>
&gt;         disadvantages of using the &#39;nsurlcredential&#39; directly:<br>
&gt;         - error credential type can lead to errors.<br>
&gt;<br>
&gt;         With discussions with Matthias, we are more keen in following<br>
&gt;         the HTTPBasicDigestAuthenticationModule<br>
</div>&gt;         &lt;<a href="https://github.com/cvasilak/aerogear-ios/blob/basic.digest.auth/AeroGear-iOS/AeroGear-iOS/security/AGHttpBasicDigestAuthentication.m" target="_blank">https://github.com/cvasilak/aerogear-ios/blob/basic.digest.auth/AeroGear-iOS/AeroGear-iOS/security/AGHttpBasicDigestAuthentication.m</a>&gt; approach<br>






<div>&gt;         instead of providing the NSURLCredential<br>
</div>&gt;         &lt;<a href="http://developer.apple.com/library/ios/#Documentation/Cocoa/Reference/Foundation/Classes/NSURLCredential_Class/Reference/Reference.html" target="_blank">http://developer.apple.com/library/ios/#Documentation/Cocoa/Reference/Foundation/Classes/NSURLCredential_Class/Reference/Reference.html</a>&gt; configuration<br>






<div>&gt;         option on the Pipe. Surely enough, in the documentation we will<br>
&gt;         explicitly state that &quot;login&quot;/ &quot;logout&quot; methods,  serve as a<br>
&gt;         mean to setup internally the iOS authentication system so users<br>
&gt;         don&#39;t have too (instead of calling remote endpoints)<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;     While the &quot;NSURLCredential&quot; better fits the meanings of BASIC/DIGEST<br>
&gt;     (no explicit login/logout against a server), however that will cause<br>
&gt;     all sorts of issues, since the APP_DEVELOPER is reponsible for<br>
&gt;     providing the NSURLCredential; If we uses a _permanent_ storage, all<br>
&gt;     sorts of errors may occur (like Christos was already indicating).<br>
&gt;<br>
&gt;<br>
&gt;     I (currently) like the &quot;auth_module&quot; approach better. However, as<br>
&gt;     Christos mentioned, we need to state (in API docs) that login/logout<br>
&gt;     is JUST applying/removing the credentials. The doc needs to say that<br>
&gt;     on LOGIN (for instance) no request is hit against the server.<br>
&gt;<br>
&gt;<br>
&gt;     -Matthias<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;         Wdyt?<br>
&gt;<br>
&gt;         Thanks,<br>
&gt;         Christos<br>
&gt;<br>
&gt;<br>
&gt;         _______________________________________________<br>
&gt;         aerogear-dev mailing list<br>
</div>&gt;         <a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a> &lt;mailto:<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a>&gt;<br>





<div>&gt;         <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;     --<br>
&gt;     Matthias Wessendorf<br>
&gt;<br>
&gt;     blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>
&gt;     sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>
&gt;     twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a><br>
&gt;<br>
&gt;     _______________________________________________<br>
&gt;     aerogear-dev mailing list<br>
</div>&gt;     <a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a> &lt;mailto:<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a>&gt;<br>





&gt;     <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
<div>&gt;<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; aerogear-dev mailing list<br>
&gt; <a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
</div></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br><br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>

sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div></div>
_______________________________________________<br>aerogear-dev mailing list<br><a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></blockquote>



</div><br></div></div></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br>



<br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>



twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div></div>
_______________________________________________<br>aerogear-dev mailing list<br><a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></blockquote>


</div><br></div></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br>


<br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>


twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div></div>
_______________________________________________<br>aerogear-dev mailing list<br><a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></blockquote>

</div></div><br></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br>

<br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>

twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div></div>
_______________________________________________<br>aerogear-dev mailing list<br><a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></blockquote>
</div><br></div></div></div></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br>
<br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>
twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div></div>