By omarpta on 2018-09-17 10:04:22 [link]

Hi there is some way to provide https protocol with certificate using wapp?

Thanks, Omar

By drh on 2018-09-17 11:43:51 [link]

I run Wapp apps as CGI behind a traditional webserver that takes care of the TSL for me. There is (current) no way for wapp to do the TSL itself.

But your patches are welcomed!

By omarpta on 2018-09-17 11:54:56 [link]

Ok thanks. What about headers? How can i get headers from the request and set some header?

By drh on 2018-09-17 13:40:34 [link]

I don't understand the question. Please elaborate.

By omarpta on 2018-09-17 14:30:52

I'm creating some Basic Authentication engine using Wapp.


And end up with this implementation. I don't know if it's the best way to do it. (sorry about formatting)

proc wapp-page-flush {} {

set authorization [wapp-param .hdr:AUTHORIZATION]

if {$authorization eq ""} {

wapp-reply-code 401

wapp-reply-extra "WWW-Authenticate" "Basic realm=\"User Visible Realm\""

} else {

wapp-subst {

  received authorization, verifying user