This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Create User with DB
#1
Hi all,

I add a user to the database like this :

Code:
    local user = {
        name = db:escape(name),
        login = db:escape(login),
        password = hashpassword(db:escape(login), "123456"),        
        homepage = "apps-fcs",        
        access_apps = "P",        
        access_vis = '',
        access_mosaic = "F",
        access_schedulers = '',
        access_trends = '',        
        allow_objects = "",        
        active = 1
    }
    
    result, err = db:insert('users', user)
    io.readproc('/etc/init.d/nginx reload')

The user is added, but when I'm try to connect, I get a 403 error !

any idea ?

thanks
Reply


Messages In This Thread
Create User with DB - by Fcs - Yesterday, 10:21
RE: Create User with DB - by admin - Yesterday, 12:23
RE: Create User with DB - by Fcs - Yesterday, 14:06
RE: Create User with DB - by admin - Yesterday, 14:10

Forum Jump: