Hello,

using the Wt tutorial, I was able to throw up a little Wt app.

The next phase was adding authentification. I tried to follow the Auth 
tutorial. Eventually, I succeeded (mostly) but it was very hard.

As a token of my appreciation of Wt, I'm taking the time to list the 
problems I encountered. This is mostly negative of course, but should 
not be taken badly ;-) This is a contribution ;-)

First the tutorial is hard to find. The link to it is hidden in the Wt 
tutorial. I had to search "auth" whithin the page find it. It should be 
given along the other tutorials in the Wt documentation page. It should 
also be clearly given at the end of the Wt tutorial since it's a 
logicial sequel. The tutorials would clearly benefit from having at the 
end a clear list of the most important links : other tutorials, live 
examples, documentation. So we wouldn't have to read the tutorial again 
to find the links hidden in some paragraph.

Then I had trouble including the Auth headers, until I realized that the 
version in Pau Garcia's PPA doesn't include auth yet. I had to download 
and compile wt latest from git.

Then in ยง2 "Configuring authentication"
- discrepancy in the name of the global variables in the 3 service class 
getters
- should outline that those 3 getters are static (maybe should give the 
.h ?)
- it was unclear that configureAuth() was static. I had a compiler error 
before realizing.

The implementation of Session::users() is not given. Since it as trivial 
as the login() function, it could be given in the .h as well.

In fact, so much code is missing. I had so much trouble trying to use 
auth following only the tutorial that I began to look for an archive 
containing the sources of the tutorial. Usually, there is a link in 
tutorials to an archive containing the example of the tutorial. But not 
here... Eventually, I guessed that it would be in the examples along Wt 
sources. But it was not clear and should be at last hinted in the tutorial.

Then, reading the hangman example, I was able to scrap enough code to 
compile some kind of auth widget. The code of the tutorial is already 
outdated, the AuthWidget no longer has methods addPasswordAuth() and 
addOAuth(). It now use an authModel, which is a new thing.

The launching method (using a WServer) is totally different from the one 
in the Wt tutorial (WRun). It was puzzling. Which one should be used ? 
What are the differences ?

Then, executing the app, I discovered that the AUthWidget needed strings 
from a messageResourceBundle. It was said nowhere. The strings that 
should be declared are not listed.

Eventually, I was able to register and login/logout. Ouf !

I then found a lot of bugs, but this is for another post ;-)

Best regards,
Offirmo.


------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
witty-interest mailing list
witty-interest@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to