Re: Authentication in sinatra
Surya Poojary <[email protected]> Sun, 12 Jan 2020 16:30:15 +0530
| Newsgroups | gmane.comp.lang.ruby.general |
|---|---|
| Message-ID | <CAANzoREitfZeehKqa2XC+Xe4DCdJeLN-jTmV4rGB0HB6PtT+zw@mail.gmail.com> |
--===============0109908420== Content-Type: multipart/alternative; boundary="00000000000039f32d059bef445c" --00000000000039f32d059bef445c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable So if they open it again ..they have to enter the password again..right ? Regards, Surya. On Sun, 12 Jan 2020, 16:23 Ketan Patel, <[email protected]> wrote: > Most browsers will cache the username/password so you don=E2=80=99t have = to enter > it on every page reload and will delete them when the browser is closed. > > Ketan Patel > > > > > On 12 Jan 2020, at 10:43, Surya Poojary <[email protected]> wrote: > > > > Will it ask for authentication everytime someone visits the URL ? or is > it if I enter correct combination once,it will not ask again .? > > > > > > Regards, > > > > Surya. > > > > On Sun, 12 Jan 2020, 16:03 Ketan Patel, <[email protected]> wrote: > > The easiest thing to start with is HTTP basic auth, have a look here: > http://sinatrarb.com/faq.html#auth. > > > > Ketan Patel > > > > > > > On 12 Jan 2020, at 10:15, Surya Poojary <[email protected]> wrote: > > > > > > Dear Rubyists, > > > > > > I'm a web developer newbie , learning sinatra . I'm planning to build > my own notes web app. Since it's for my personal use , I want the home pa= ge > to be a classic login page where I can enter my username and password and > then it should show me all my notes otherwise it shouldn't show . > > > > > > How do I achieve this with Sinatra? > > > > > > Regards, > > > Surya. > > > > > > > > > Unsubscribe: <mailto:[email protected] > ?subject=3Dunsubscribe> > > > <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk> > > > > > > Unsubscribe: <mailto:[email protected] > ?subject=3Dunsubscribe> > > <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk> > > > > Unsubscribe: <mailto:[email protected] > ?subject=3Dunsubscribe> > > <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk> > > > Unsubscribe: <mailto:[email protected]?subject=3Dunsubscrib= e> > <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk> > --00000000000039f32d059bef445c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"auto">So if they open it again ..they have to enter the passwor= d again..right ?<div dir=3D"auto"><br></div><div dir=3D"auto"><br></div><di= v dir=3D"auto">Regards,</div><div dir=3D"auto"><br></div><div dir=3D"auto">= Surya.</div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr">On Sun, 1= 2 Jan 2020, 16:23 Ketan Patel, <<a href=3D"mailto:[email protected]">ketp= [email protected]</a>> wrote:<br></div><blockquote class=3D"gmail_quote" styl= e=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Most br= owsers will cache the username/password so you don=E2=80=99t have to enter = it on every page reload and will delete them when the browser is closed.<br= > <br> Ketan Patel<br> <br> <br> <br> > On 12 Jan 2020, at 10:43, Surya Poojary <<a href=3D"mailto:suryapjr= @gmail.com" target=3D"_blank" rel=3D"noreferrer">[email protected]</a>>= wrote:<br> > <br> > Will it ask for authentication everytime someone visits the URL ? or i= s it if I enter correct combination once,it will not ask again .?<br> > <br> > <br> > Regards,<br> > <br> > Surya.<br> > <br> > On Sun, 12 Jan 2020, 16:03 Ketan Patel, <<a href=3D"mailto:ketpat@g= mail.com" target=3D"_blank" rel=3D"noreferrer">[email protected]</a>> wro= te:<br> > The easiest thing to start with is HTTP basic auth, have a look here: = <a href=3D"http://sinatrarb.com/faq.html#auth" rel=3D"noreferrer noreferrer= " target=3D"_blank">http://sinatrarb.com/faq.html#auth</a>.<br> > <br> > Ketan Patel<br> > <br> > <br> > > On 12 Jan 2020, at 10:15, Surya Poojary <<a href=3D"mailto:sur= [email protected]" target=3D"_blank" rel=3D"noreferrer">[email protected]</a= >> wrote:<br> > > <br> > > Dear Rubyists,<br> > > <br> > > I'm a web developer newbie , learning sinatra . I'm plann= ing to build my own notes web app. Since it's for my personal use , I w= ant the home page to be a classic login page where I can enter my username = and password and then it should show me all my notes otherwise it shouldn&#= 39;t show . <br> > > <br> > > How do I achieve this with Sinatra?<br> > > <br> > > Regards,<br> > > Surya.<br> > > <br> > > <br> > > Unsubscribe: <mailto:<a href=3D"mailto:ruby-talk-request@ruby-= lang.org" target=3D"_blank" rel=3D"noreferrer">ruby-talk-request@ruby-lang.= org</a>?subject=3Dunsubscribe><br> > > <<a href=3D"http://lists.ruby-lang.org/cgi-bin/mailman/options= /ruby-talk" rel=3D"noreferrer noreferrer" target=3D"_blank">http://lists.ru= by-lang.org/cgi-bin/mailman/options/ruby-talk</a>><br> > <br> > <br> > Unsubscribe: <mailto:<a href=3D"mailto:ruby-talk-request@ruby-lang.= org" target=3D"_blank" rel=3D"noreferrer">[email protected]</= a>?subject=3Dunsubscribe><br> > <<a href=3D"http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby= -talk" rel=3D"noreferrer noreferrer" target=3D"_blank">http://lists.ruby-la= ng.org/cgi-bin/mailman/options/ruby-talk</a>><br> > <br> > Unsubscribe: <mailto:<a href=3D"mailto:ruby-talk-request@ruby-lang.= org" target=3D"_blank" rel=3D"noreferrer">[email protected]</= a>?subject=3Dunsubscribe><br> > <<a href=3D"http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby= -talk" rel=3D"noreferrer noreferrer" target=3D"_blank">http://lists.ruby-la= ng.org/cgi-bin/mailman/options/ruby-talk</a>><br> <br> <br> Unsubscribe: <mailto:<a href=3D"mailto:[email protected]" = target=3D"_blank" rel=3D"noreferrer">[email protected]</a>?su= bject=3Dunsubscribe><br> <<a href=3D"http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk= " rel=3D"noreferrer noreferrer" target=3D"_blank">http://lists.ruby-lang.or= g/cgi-bin/mailman/options/ruby-talk</a>><br> </blockquote></div> --00000000000039f32d059bef445c-- --===============0109908420== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline Unsubscribe: <mailto:[email protected]?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk> --===============0109908420==--