ssl encryption with post_form()

  • Thread starter Robbie Mckennie
  • Start date
R

Robbie Mckennie

im writing a program that needs to post a form, and iv found that i can
do this with post_form(), but i need to send it over a connection with
ssl encryption. heres my code

require 'net/http'
require 'uri'
res = Net::HTTP.post_form(URI.parse('http://the/url'),
{
'my test' => 'variables'
}
)
puts res.body

and that works, but without ssl. i wanted somthing like this

require 'net/http'
require 'uri'
res = Net::HTTP.post_form(URI.parse('http://the/url'),
{
'my test' => 'variables'
}
)
res.ssl = true
puts res.body

but i havnt found anything. hope i have been clear
 
A

Ammar Ali

im writing a program that needs to post a form, and iv found that i can
do this with post_form(), but i need to send it over a connection with
ssl encryption. heres my code
but i havnt found anything. hope i have been clear

Did you try googling for "ruby https post"? The first few results will
have some answers.

Regards,
Ammar
 
R

Robbie Mckennie

Ammar Ali wrote in post #959518:
Did you try googling for "ruby https post"? The first few results will
have some answers.

Regards,
Ammar

<sarcasm>
hee, thanks, i didnt think to google it
</sarcasm>

i already tried that, didnt help
 
A

Ammar Ali

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

post_form 1
Net::HTTP and post_form 0
posting form data in ruby 1.8.2? 2
Net::http 2
HTTP request, with headers, post data and SSL :( 4
ruby https post 1
help me with Net::HTTP 1
post_form not posting to full url 1

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top