B4J Question authentication identity check at server?

MarkusR

Well-Known Member
Licensed User
Longtime User
I try to use this solution with ssl:
[Server] Data Collection Solution - Device, Desktop and Web reports
https://www.b4x.com/android/forum/t...device-desktop-and-web-reports.37254/#content

In the DataCollectionDesktop App i will use Username & Password (https://)
B4X:
Dim j As HttpJob
j.Username = "..."
j.Password = "..."

My Question:
At DataCollectionServer its possible to Check this User/Password via Filter Class?



I initialize Server with this:
B4X:
    srvr.Initialize("srvr")
    Dim ssl As SslConfiguration
    ssl.Initialize
    ssl.SetKeyStorePath(File.DirApp, "server.keystore")
    ssl.KeyStorePassword = "..."
    'ssl.KeyManagerPassword = "..."
    srvr.SetSslConfiguration(ssl, 443)
    srvr.AddFilter("/*", "HttpsFilter", False)
    srvr.AddDoSFilter("/*",Null) '  
    Log(File.DirApp)
 
    srvr.StaticFilesFolder = File.Combine(File.DirApp, "www")
    srvr.AddHandler("/hello", "HelloPage", False)
    srvr.Start
    StartMessageLoop
 
Last edited:

MarkusR

Well-Known Member
Licensed User
Longtime User
Note that it is an old example. If I remember correctly it is not based on B4XSerializator. I recommend you to switch to B4XSerializator.
exact that example code from you with BasicAuthenticationFilter i looked for, thanks. :)
You are right, i need B4XSerializator.
i approach my goal.
 
Last edited:
Upvote 0
Top