Is there a way to write Audit log messages on the old log server (pre 2018R3)?

Please explore the Log Message Server sample -

https://doc.developer.milestonesys.com/html/index.html?base=samples/logmessagetoserver.html&tree=tree_2.html

Rie,

I know that example and it work fine up to 2018R3 (SurveillanceLogServerV2) but not on previous version with SurveillanceLogServer

Frediano

I tested Log Message Server sample following version and it worked fine;

XProtect Corporate : 2018 R2

MIP SDK : 2019 R3

If you used old version of MIP SDK such as 2018 R2 or R3, can you please test the newest version of MIP SDK(2019 R3)?

I’m using MIP SDK 2019R2 and there is nothing about this on R3 release note

Frediano

This is a big mystery, because I tested the Log Message Server sample:

  1. MIP SDK 2019 R2 and XProtect Corporate 2018 R2

  2. MIP SDK 2019 R2 and XProtect Corporate 2018 R3

Does the logging work in general? Do you see the correct audit logs logging when a user uses the Smart Client?

Rie,

I am developing an App (Component Integration) to export video recording also if user can’t see it. Those below are log messages recorded on XPCO 2019R2 (VideoExport is App name)

Export Log - 2019R2

I made same operation on XPCO 2018R2 and the result is

In both cases use login are recorded, in the first case two times: one from normal logging and other from my app

Frediano

Please run the Log Message Server sample, does the unmodified sample work or do you see a similar issue?

When you login from the unmodified sample, you may see a login entry (see below, red square). When you click Test bottom in the sample, you may see the similar log entry in the blue square (see below). Please remember to refresh when you see the logs.

Rie,

I compiled the sample app with Visual Studio 2019 updated to the last revision and I did the tests both on my development computer (XPCO 2019R2), and on a Client platform (XPCO 2018R2).

Before showing the results let me list what should I expect:

  • “Start Recording” Button: Message = “Start Record command issued for {selected camera}”, Register = “System” (Method = “NewEntry”, Group = “Group.System”, Category = “UserAction”)
  • “Stop Recording” Button: Message = “Stop Record command issued for {selected camera}”, Register = “System” (Method = “NewEntry”, Group = “Group.System”, Category = “UserAction”)
  • “Test” button: 2 messages
  1. Message = “Card holder swiped at Door 25-1 card holder ABCs Card 日本語”, Permission = “Granted”, Register = “System” (Method = “AuditEntry”, Group = “Group.Audit”, Category = “UserAction” )
  2. Message = “Card holder swiped at Door 25-1 card holder ABCs Card 日本語”, Permission = “Denied”, Register = “System” (Method = “AuditEntry”, Group = “Group.Audit”, Category = “UserAction” )

These are the results obtained on 2019R2:

System Register:

Log Sistema 2019R2

Audit Register

Log Utente 2019R2

Log Messages are right but the “UserAction” Category is not recognized as valid!

These are the results obtained on 2018R2:

Just after login e camera selection to see the time

System Register

… no system logs after 09:41

Audit Register

… as you can see also here any log was generated by the app, even if the system has logged the Recording Start / Stop operations as “Events defined by the user”.

Finally I didn’t find any meaningful messages on the log file of Log Server.

Frediano

Are you communicating across the servers? Or are you using the sample running directly in the customers server?

Yes, I ran the sample app on the customer machine where alla server SW are running

What kind of user are you using?

Is it in administrator group?

Is it Basic user or Windows user?

Window User with administrative profile

Il Ven 13 Dic 2019, 15:41 Milestone Developer Forum <
noreply@milestonesys.com> ha scritto:

Finally, we could see the same symptom when we changed the language from English to Italian in Management Client. Please see below code in the LogMessageToServer sample, when you use English or Danish then you can see logs that you expect. So please add your language that you want to use in the sample.

-–

LogResourceHandler.cs

internal static void RegisterMyMessages()
{
    LogMessageDictionary lmd1 = new LogMessageDictionary("en-US", "3.8", _myApplication, _myComponent, BuildDictionary("en-US"), "AccessControl");
    LogMessageDictionary lmd2 = new LogMessageDictionary("da-DK", "3.8", _myApplication, _myComponent, BuildDictionary("da-DK"), "AccessControl");
 
    VideoOS.Platform.Log.LogClient.Instance.RegisterDictionary(lmd1);
    VideoOS.Platform.Log.LogClient.Instance.RegisterDictionary(lmd2);
}

Rie,

I don’t understand, this is my code …

        internal static void RegisterLogMessages()
		{
			// Inglese
            LogMessageDictionary lmdEN = new LogMessageDictionary("en-US", "v3.3", _myApplication, _myComponent, BuildDictionary("en-US"), "EXTERNAL" );
            LogClient.Instance.RegisterDictionary(lmdEN);
            // Italiano
            LogMessageDictionary lmdIT = new LogMessageDictionary("it-IT", "v3.3", _myApplication, _myComponent, BuildDictionary("it-IT"), "EXTERNAL");
			LogClient.Instance.RegisterDictionary(lmdIT);
        }

Because I have 2 languages, English and Italian, I am using 2 LogMessageDictionary, English and Italian; do I have to add Danish one?

Freddy

Actually, the only difference is v3.3 instead of v3.8

Freddy

Hi,

First of all, your modification was correct. We could also see the same symptom when we changed to other languages (fx, Japanese or Danish) in the code and Management Client(tools → Options).

For the clarification of this issue, may I ask you a few more things?

Can you see correct Italian logs in Audit log when you use the latest server(2019R3) and latest SDK(2019R3)?

Can you see correct English logs in Audit log when you use the 2018R2 server and latest SDK(2019R3)? (Please change language in Management Client → tools → options)

Rie, I made the test you ask for:

  • Corporate 2018R2
  • Corporate 2019R3

both with the App compiled with SDK 2019R2 and 2019R3.

On 2019R3, indipendently from the language set (Italian and English), I can see log messages.

On 2018R2 I can’t see anything with Italian language but setting English language I can see all, as you can see on the following image

Both Apps use English terms for Category (Security, Export, …); could be this the problem?

In order to do some tests using Italian Category, where can I find definitions

Many thanks,

Frediano

Hi Frediano,

Thank you for the tests. We also tested in the same way and were able to see the issue.

Milestone Development will start investigation.

Best regards,​

Rie​

Hi Frediano,

We fixed this issue. We made a hotfix and can you please test it? Please click following link and download it.

http://download.milestonesys.com\MIPSDK\HOTFIX\TFS289020

Best regards,

Rie