Re: getting login name in 4GL
Posted in 1996
: Tim Schaefer <tschaefe@encore.com> writes: : The original question of getting the : login id is perhaps ( in my little world at least ) involved with a : two-fold process: : : 1 - get the login from the OS ( for me most likely UNIX ) : 2 - get more info about a user from a look-up table : : These two processes are distinct enough, and can be managed quite : simply, which I think we are all probably in agreement on. My little : point was to make sure, hopefully without a doubt that the user id to : query-on in a look-up table is really the one I want. The OS should : be able to provide this accurately. From there, I go to a table to : look-up detail information about a user, as you suggest. If you have : a lot of users in a rather large company, and there is always a turnover : of personnel, you can set up a cron to update the user-detail-table : with the most current information nightly from a password file. This : seems to be quite reliable. The use of the USER variable is quite : unreliable, as well as just using data base information solely without : checking the OS for the user id. : : Sometimes it's not just users, but investors and auditors we must satisfy. Yes, indeed. But have you ever come across a situation where you get one user id from the OS and another from the engine (select user from ...). If you have we would sertanly like to here about it. That may be a very serious security hole somewhere. I could imagine this happen in a client/server configuration, but we would still like to here about that. As I said, if the user-name returned from the engine can't be trusted than grants and revokes of access rights also can't be trusted. We use a combination of a user table as you describe and grants to give users access to programs and data in the database. If we can't trust the grants, what are we then to do. We don't like the idea of having to implement a complete security system inside all applications. Nils.Myklebust@ccmail.telemax.no NM Data AS, Postbox 9090, Gronland, 0133 Oslo, Norway My opinions are those of my company