Getting the Network Username for Metastorm Guest Users

I want to obtain the Network Username for Users in a form as a Metastorm Guest.

I have tried a few SQL statements, but am getting nowhere.

It must be get able!

anyone got any ideas, ideally need to get the info as the form opens

 

Tagged:

Comments

  • The problem is that the engine only know's the user as "eGuest".

     

    Basically it has recieved an annoymous blank form action request.  Because Guest User Access is enabled it bypasses the normal authentication and generates a eSessionID for the user "eGuest".  The action request is processed using that eSessionID and a response is returned to the client.

     

    As the whole conversation is annoymous there is no way for the engine to know the user's network name. 

  • Trouble is our staff are supposed to name themselves when filling in the request form (eguest), but the wonderful people do not always do so, even if you make it a required field. I have vbs code that goes off and picks up the Network D of a user, surely there must be a SQL way of doing the same thing? see below

     

    Dim sCurrentNetworkLoginName As String
    Dim Scriteria As String

    sCurrentNetworkLoginName = ap_GetUserName
    Scriteria = "NetworkLoginName = '" & Trim(sCurrentNetworkLoginName) & "'"

     

    Declare Function wu_GetUserName Lib "advapi32.dll" Alias "GetUserNameA" (ByVal lpBuffer As String, nsize As Long) As Long
    Declare Function wu_GetComputerName Lib "Kernel32.dll" Alias "GetComputerNameA" (ByVal lpBuffer As String, nsize As Long) As Long

    Function ap_GetUserName() As Variant
        Dim strUserName As String
        Dim lnglength As Long
        Dim lngResult As Long
        ' setup the buffer for name
        strUserName = String$(255, 0)
        lnglength = 255
       
        ' make the call for the data
        lngResult = wu_GetUserName(strUserName, lnglength)
       
        ' assign the value to the function and tidy up
        ap_GetUserName = Left(strUserName, InStr(strUserName, Chr$(0)) - 1)
       
    End Function

     

    sorry this took so long to reply to, got taken off that project to do something else for a while....

    thanks for replying:smileyhappy:

    rosemary

  • Hi,

     

    I am assuming that is bein run as client side code? 

     

    If that is the case it is going to find the user and and user on the client PC and return it to where it is called on the form (provided the browser security alows it) and from there is can be sent to the engine simply as another piece of data.

     

    If you do run it on the engine I am assuming it would only find the Service Account details for the Metastorm Engine Service?

     

    The key problem is that without any form of SSO login the end user's credentials are simply not being passed though to the Metastorm Engine, let alone to the database.

     

  • sounds like you think it might work, I might try to convert it to SQL then.

  • No sorry that is not what I meant. There is no way for the DB to know who the end user is unless the credentials of that user has been passed through the Metastorm engine and even then it is simply being stored as a string. The engine will never be impersonating an end user.

    Similarly there is no way the engine will know who an end user is unless the credentials have been passed to the engine is some way...

    Does that make sense?

    Paul

  • I am only looking at this from the perspective of an internal staff member using a metastorm fom, via our Intranet.

    If I can get the information via a call to the network information being held on the pc file, pass that information to the table by using a 'do this' when they enter data into a required field, then I can use that information to identify what name they are logged into our network under.

    I am confused, if they are on our network, we know who they are, if they are in a metastorm form as an eguest they are still on our network, so I can find out who they are and be able to pass that info to a field in the table on the database.

    Yes?

     

    rosemary

     

  • The mechanisim is that while the end user is on the network using their Browser, it depends how the Web Site is configured that determines whether those credentials are passed on to the engine.

     

    If the Web Site is configured for annoymous access then the the web site is not recording who you are and is then not passing that information on the the Metastorm BPM Engine, it is effectively filtering out your network credentials.

     

    If you need to know which staff are using a form why not enabled SSO authentation rather the eGuest access?  They will still be passed directly to the form but the engine will have had their credentials passed to it...

  • I thought they had to log in to use SSO?

     

  • Yes that is correct, however the user will not see a Metastorm login prompt, rather they will be automatically logged into Metastorm based on their network credentials. 

     

    This should be pretty straightforward for internal users...

     

     

  • If you cannot use SSO or the standard authentication scripts then you have the option to create a custom authentication script using the open authentication framework, details of which are in the documentation set for Metastorm. Maybe worth a look.....