<div dir="ltr">Hi,<div><br></div><div style>The code works fine on 15B, I know how to use the post. Please read what I am typing :)</div><div style><br>When I say "it doesn't work", I of course mean the error in the OP.</div>
<div style><br>Regards,<br>Aaron</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 31, 2013 at 11:47 AM, Bogdan Andu <span dir="ltr"><<a href="mailto:bog495@gmail.com" target="_blank">bog495@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div>what does tit mean "it doesn't work for me"?<br><br></div>you can POST a Body of data to an Url like this:<br>
<br></div>httpc:request(post, {"<a href="https://region-b.geo-1.identity.hpcloudsvc.com:35357/" target="_blank">https://region-b.geo-1.identity.hpcloudsvc.com:35357/</a>",<br>
[{"Content-Length", ContentLength}],<br> ContentType,<br> Body},<br> [], []).<br><br></div>you have to make the Body and compute the length of the Body yourself.<br>
<br></div>Best Regards and good luck<span class="HOEnZb"><font color="#888888"><br><br>Bogdan<br></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 31, 2013 at 12:30 PM, Aaron France <span dir="ltr"><<a href="mailto:aaron.l.france@gmail.com" target="_blank">aaron.l.france@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Right, but it doesn't work for me. It's also an endpoint where you need to post/get w/ specific bodies, perhaps that's getting in the way?</div>
<div><div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Fri, May 31, 2013 at 11:25 AM, Bogdan Andu <span dir="ltr"><<a href="mailto:bog495@gmail.com" target="_blank">bog495@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">it works!<br></div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 31, 2013 at 12:17 PM, Aaron France <span dir="ltr"><<a href="mailto:aaron.l.france@gmail.com" target="_blank">aaron.l.france@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">What's this telling you?</div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Fri, May 31, 2013 at 11:02 AM, Bogdan Andu <span dir="ltr"><<a href="mailto:bog495@gmail.com" target="_blank">bog495@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><br></div>Tried this:<br><br>$ erl<br>Erlang R16B (erts-5.10.1) [source] [64-bit] [smp:2:2] [async-threads:10] [kernel-poll:false]<div>
<br><br>Eshell V5.10.1 (abort with ^G)<br></div>1> inest:start().<br>** exception error: undefined function inest:start/0<br>
2> inets:start().<br>ok<br>3> ssl:start().<br>ok<br>4> httpc:request("<a href="http://region-b.geo-1.identity.hpcloudsvc.com:35357/" target="_blank">http://region-b.geo-1.identity.hpcloudsvc.com:35357/</a>").<br>
{error,socket_closed_remotely}<br>
5> httpc:request("<a href="https://region-b.geo-1.identity.hpcloudsvc.com:35357/" target="_blank">https://region-b.geo-1.identity.hpcloudsvc.com:35357/</a>").<div><br>{ok,{{"HTTP/1.1",200,"OK"},<br>
[{"cache-control","no-cache"},<br></div>
{"date","Fri, 31 May 2013 08:59:44 GMT"},<div><br> {"pragma","no-cache"},<br> {"server","Apache-Coyote/1.1"},<br> {"content-length","1080"},<br>
{"content-type","application/json"},<br> {"expires","-1"}],<br></div> "{\n \"versions\" : {\n \"otherAttributes\" : {\n },\n \"version\" : [ {\n \"id\" : \"v1.0\",\n \"otherAttributes\" : {\n },\n \"status\" : \"DEPRECATED\",\n \"updated\" : \"2012-06-20T08:59:45.110Z\"\n }, {\n \"id\" : \"v1.1\",\n \"link\" : [ {\n \"href\" : \"<a href="https://docs.hpcloud.com/api/identity%5C" target="_blank">https://docs.hpcloud.com/api/identity\</a>",\n \"rel\" : \"describedby\",\n \"type\" : \"text/html\"\n } ],\n \"otherAttributes\" : {\n },\n \"status\" : \"CURRENT\",\n \"updated\" : \"2012-06-20T08:59:45.110Z\"\n }, {\n \"id\" : \"v2.0\",\n \"link\" : [ {\n \"href\" : \"<a href="https://docs.hpcloud.com/api/identity%5C" target="_blank">https://docs.hpcloud.com/api/identity\</a>",\n \"rel\" : \"describedby\",\n \"type\" : \"text/html\"\n } ],\n \"otherAttributes\" : {\n },\n \"status\" : \"CURRENT\",\n \"updated\" : \"2012-06-20T08:59:45.110Z\"\n }, {\n \"id\" : \"v3.0\",\n \"link\" : [ {\n \"href\" : \"<a href="https://docs.hpcloud.com/api/identity%5C" target="_blank">https://docs.hpcloud.com/api/identity\</a>",\n \"rel\" : \"describedby\",\n \"type\" : \"text/html\"\n } ],\n \"otherAttributes\" : {\n },\n \"status\" : \"BETA\",\n \"updated\" : \"2013-04-25T08:59:45.110Z\"\n } ]\n }\n}"}}<br>
6> <br><br></div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 31, 2013 at 10:28 AM, Aaron France <span dir="ltr"><<a href="mailto:aaron.l.france@gmail.com" target="_blank">aaron.l.france@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div><br>I'm using httpc, so I tried: httpc:set_options([{socket, {verify, verify_none}}]). and I still receive the same error.</div>
<div><br></div><div>That's correct? If not; let me know. Thanks!</div>
<div><br></div><div>Regards,<br>Aaron</div></div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, May 31, 2013 at 9:19 AM, Bogdan Andu <span dir="ltr"><<a href="mailto:bog495@gmail.com" target="_blank">bog495@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">may be the ssl stack changed a bit and some defaults parameters.<br><div><br>you may try to pass the ssl option {verify, <span>verify_none</span>} to ssl:connect function and see what happens.<br>
<br>
</div><div>Bogdan<br></div></div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, May 30, 2013 at 10:17 PM, Aaron France <span dir="ltr"><<a href="mailto:aaron.l.france@gmail.com" target="_blank">aaron.l.france@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>But why is it working on R15B? Is the ssl code basically broken on R15B?</div></div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, May 30, 2013 at 9:12 PM, <span dir="ltr"><<a href="mailto:bog495@gmail.com" target="_blank">bog495@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br><br>verify the output of the command:<br><br>$ openssl s_client -connect <a href="http://region-b.geo-1.identity.hpcloudsvc.com:35357" target="_blank">region-b.geo-1.identity.hpcloudsvc.com:35357</a><br>
ogdan<br>it seems that there is a certificate self signed.<br><br>May be a solution is to disable certificate verification on peer and see what happens.<br><br>Bogdan<div><div><br><br>On Thursday, May 30, 2013 5:43:04 PM UTC+3, Aaron France wrote:<blockquote class="gmail_quote" style="margin:0;margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Hi,<div><br></div><div>I'm trying to make HTTPS calls to an API.</div><div><br></div><div>My stack trace is:</div><div><br></div><div><div>SSL: certify: ssl_handshake.erl:263:Fatal error: certificate unknown</div>
<div>** exception error: no match of right hand side value </div><div> {error,</div><div> {failed_connect,</div><div> [{to_address,</div><div> {"<a href="http://region-b.geo-1.identity.hpcloudsvc.com" target="_blank">region-b.geo-1.identity.<u></u>hpcloudsvc.com</a>",35357}},</div>
<div> {inet,[inet],{tls_alert,"<u></u>certificate unknown"}}]}}</div><div> in function herp_identity:login/3 (src/herp_identity.erl, line 9)</div><div><br></div><div>I've looked at some other issues which point it to being a regression in R16B and I've reverted to R15 and the issue is non-existent.</div>
<div><br></div><div>Any tips on getting around this or will it require a patch in R16B? The bug is still evident in HEAD so possibly not enough data has been gathered about it.</div><div><br></div><div>
Regards,<br>Aaron</div></div></div>
</blockquote></div></div><br>_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>