11:24, EEST
May 29, 2020
12:07, EEST
April 3, 2012
3:16, EEST
May 29, 2020
Bjarne Boström said
Hi,Please clarify what do you mean?
I do not exactly understand the question as the Session is given as parameter for onValidate and onValidationError methods of UserValidator? Â
I need to test if the OPC UA Server SDK can be achieved, distinguish Client’s IP
It is known that [public boolean onValidate(Session session, ServerUserIdentity userIdentity)] in MyUserValidator class
Among them, variable session can get the Client’s IP
So I want to get the client’s ip and variable ServerUserIdentity in Class MyNodeManagerListener how can I do ?
thanks!!
9:13, EEST
April 3, 2012
You can get the Session from the ServiceContext (via getSession()), which is given as the first parameter in many listener interfaces. This is shown e.g. in the MyNodeManagerListener sample with the checkUserAccess method which is called from the interface implementing methods. And then you can get the ServerUserIdentity from the Session.getUserIdentity().
8:36, EEST
May 29, 2020
Bjarne Boström said
You can get the Session from the ServiceContext (via getSession()), which is given as the first parameter in many listener interfaces. This is shown e.g. in the MyNodeManagerListener sample with the checkUserAccess method which is called from the interface implementing methods. And then you can get the ServerUserIdentity from the Session.getUserIdentity(). Â
Hi Bjarne Boström
thanks for your help
I did it.
Most Users Ever Online: 518
Currently Online:
20 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
hbrackel: 135
pramanj: 86
Francesco Zambon: 81
rocket science: 77
ibrahim: 75
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
fred: 41
Member Stats:
Guest Posters: 0
Members: 680
Moderators: 16
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1467
Posts: 6259
Newest Members:
ThomasWilson, elviralangwell4, Donnavek, Eddiefauth, DonaldPooma, fidelduke938316, Jan-Pfizer, DavidROunc, fen.pang@woodside.com, aytuleModerators: Jouni Aro: 1009, Otso Palonen: 32, Tuomas Hiltunen: 5, Pyry: 1, Petri: 0, Bjarne Boström: 983, Heikki Tahvanainen: 402, Jukka Asikainen: 1, moldzh08: 0, Jimmy Ni: 26, Teppo Uimonen: 21, Markus Johansson: 42, Niklas Nurminen: 0, Matti Siponen: 321, Lusetti: 0, Ari-Pekka Soikkeli: 5
Administrators: admin: 1