from Gerhard Gappmeier (ascolab):

new dissector for OPCUA protocol

svn path=/trunk/; revision=21760
This commit is contained in:
Ulf Lamping 2007-05-14 13:58:54 +00:00
parent 013332de7f
commit dd8feca514
34 changed files with 7271 additions and 0 deletions

View File

@ -225,6 +225,7 @@ plugin_ldadd = \
-dlopen plugins/lwres/lwres.la \
-dlopen plugins/mate/mate.la \
-dlopen plugins/mgcp/mgcp.la \
-dlopen plugins/opcua/opcua.la \
-dlopen plugins/opsi/opsi.la \
-dlopen plugins/pcli/pcli.la \
-dlopen plugins/profinet/profinet.la \

View File

@ -902,6 +902,7 @@ install-common-files:
xcopy ".\plugins\lwres\lwres.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\mate\mate.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\mgcp\mgcp.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\opcua\opcua.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\opsi\opsi.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\pcli\pcli.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
xcopy ".\plugins\profinet\profinet.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d

View File

@ -1480,6 +1480,7 @@ AC_OUTPUT(
plugins/lwres/Makefile
plugins/mate/Makefile
plugins/mgcp/Makefile
plugins/opcua/Makefile
plugins/opsi/Makefile
plugins/pcli/Makefile
plugins/profinet/Makefile

View File

@ -35,6 +35,7 @@ SUBDIRS = \
lwres \
mate \
mgcp \
opcua \
opsi \
pcli \
profinet \
@ -55,3 +56,4 @@ EXTRA_DIST = \
MAINTAINERCLEANFILES = \
Makefile.in

View File

@ -21,6 +21,7 @@ all: \
lwres \
mate \
mgcp \
opcua \
opsi \
pcli \
profinet \
@ -99,6 +100,12 @@ mgcp::
cd mgcp
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake
cd ..
opcua::
cd opcua
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake
cd ..
opsi::
cd opsi
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake
@ -185,6 +192,9 @@ clean:
cd mgcp
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean
cd ..
cd opcua
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean
cd ..
cd opsi
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean
cd ..
@ -254,6 +264,9 @@ distclean: clean
cd mgcp
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean
cd ..
cd opcua
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean
cd ..
cd opsi
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean
cd ..
@ -323,6 +336,9 @@ maintainer-clean: distclean
cd mgcp
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean
cd ..
cd opcua
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean
cd ..
cd opsi
$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean
cd ..
@ -371,6 +387,7 @@ install-plugins:
xcopy lwres\*.dll $(VERSION) /d
xcopy mate\*.dll $(VERSION) /d
xcopy mgcp\*.dll $(VERSION) /d
xcopy opcua\*.dll $(VERSION) /d
xcopy opsi\*.dll $(VERSION) /d
xcopy pcli\*.dll $(VERSION) /d
xcopy profinet\*.dll $(VERSION) /d
@ -387,3 +404,4 @@ clean-deps:
rm -rf $(VERSION)

6
plugins/opcua/AUTHORS Normal file
View File

@ -0,0 +1,6 @@
Author :
Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
ascolab GmbH
http://www.ascolab.com

340
plugins/opcua/COPYING Normal file
View File

@ -0,0 +1,340 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.

8
plugins/opcua/ChangeLog Normal file
View File

@ -0,0 +1,8 @@
$Id: ChangeLog,v 1.1.1.1 2006/07/12 09:17:41 gergap Exp $
Overview of changes in OpcUa plugin:
Version 0.0.1:
* initial implementation without security

275
plugins/opcua/Doxyfile Normal file
View File

@ -0,0 +1,275 @@
# Doxyfile 1.4.1-KDevelop
#---------------------------------------------------------------------------
# Project related configuration options
#---------------------------------------------------------------------------
PROJECT_NAME = opcua.kdevelop
PROJECT_NUMBER = $VERSION$
OUTPUT_DIRECTORY =
CREATE_SUBDIRS = NO
OUTPUT_LANGUAGE = English
USE_WINDOWS_ENCODING = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF = "The $name class" \
"The $name widget" \
"The $name file" \
is \
provides \
specifies \
contains \
represents \
a \
an \
the
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = YES
STRIP_FROM_PATH = /home/gergap/
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = NO
INHERIT_DOCS = YES
DISTRIBUTE_GROUP_DOC = NO
TAB_SIZE = 8
ALIASES =
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
SUBGROUPING = YES
#---------------------------------------------------------------------------
# Build related configuration options
#---------------------------------------------------------------------------
EXTRACT_ALL = NO
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = NO
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_METHODS = NO
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = YES
HIDE_SCOPE_NAMES = NO
SHOW_INCLUDE_FILES = YES
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = NO
SORT_BY_SCOPE_NAME = NO
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
SHOW_USED_FILES = YES
SHOW_DIRECTORIES = YES
FILE_VERSION_FILTER =
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = NO
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = /home/gergap/work/wireshark/plugins/opcua
FILE_PATTERNS = *.c \
*.cc \
*.cxx \
*.cpp \
*.c++ \
*.java \
*.ii \
*.ixx \
*.ipp \
*.i++ \
*.inl \
*.h \
*.hh \
*.hxx \
*.hpp \
*.h++ \
*.idl \
*.odl \
*.cs \
*.php \
*.php3 \
*.inc \
*.m \
*.mm \
*.dox \
*.C \
*.CC \
*.C++ \
*.II \
*.I++ \
*.H \
*.HH \
*.H++ \
*.CS \
*.PHP \
*.PHP3 \
*.M \
*.MM \
*.C \
*.H \
*.tlh \
*.diff \
*.patch \
*.moc \
*.xpm \
*.dox
RECURSIVE = yes
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS = *
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = NO
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = YES
REFERENCES_RELATION = YES
VERBATIM_HEADERS = YES
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = NO
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET =
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
BINARY_TOC = NO
TOC_EXPAND = NO
DISABLE_INDEX = NO
ENUM_VALUES_PER_LINE = 4
GENERATE_TREEVIEW = NO
TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = YES
LATEX_OUTPUT = latex
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
COMPACT_LATEX = NO
PAPER_TYPE = a4wide
EXTRA_PACKAGES =
LATEX_HEADER =
PDF_HYPERLINKS = NO
USE_PDFLATEX = NO
LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
GENERATE_RTF = NO
RTF_OUTPUT = rtf
COMPACT_RTF = NO
RTF_HYPERLINKS = NO
RTF_STYLESHEET_FILE =
RTF_EXTENSIONS_FILE =
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
GENERATE_MAN = NO
MAN_OUTPUT = man
MAN_EXTENSION = .3
MAN_LINKS = NO
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML = yes
XML_OUTPUT = xml
XML_SCHEMA =
XML_DTD =
XML_PROGRAMLISTING = YES
#---------------------------------------------------------------------------
# configuration options for the AutoGen Definitions output
#---------------------------------------------------------------------------
GENERATE_AUTOGEN_DEF = NO
#---------------------------------------------------------------------------
# configuration options related to the Perl module output
#---------------------------------------------------------------------------
GENERATE_PERLMOD = NO
PERLMOD_LATEX = NO
PERLMOD_PRETTY = YES
PERLMOD_MAKEVAR_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration::additions related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE = opcua.tag
ALLEXTERNALS = NO
EXTERNAL_GROUPS = YES
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = YES
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
GROUP_GRAPHS = YES
UML_LOOK = NO
TEMPLATE_RELATIONS = NO
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
CALL_GRAPH = NO
GRAPHICAL_HIERARCHY = YES
DIRECTORY_GRAPH = YES
DOT_IMAGE_FORMAT = png
DOT_PATH =
DOTFILE_DIRS =
MAX_DOT_GRAPH_WIDTH = 1024
MAX_DOT_GRAPH_HEIGHT = 1024
MAX_DOT_GRAPH_DEPTH = 1000
DOT_TRANSPARENT = NO
DOT_MULTI_TARGETS = NO
GENERATE_LEGEND = YES
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Configuration::additions related to the search engine
#---------------------------------------------------------------------------
SEARCHENGINE = NO

119
plugins/opcua/Makefile.am Normal file
View File

@ -0,0 +1,119 @@
# Makefile.am
# Automake file for OpcUa plugin
#
# $Id: Makefile.am,v 1.1.1.1 2006/07/12 09:17:41 gergap Exp $
#
# Adapted by Gerhard Gappmeier for OpcUa
# Wireshark - Network traffic analyzer
# By Gerald Combs <gerald@wireshark.org>
# Copyright 1998 Gerald Combs
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
INCLUDES = -I$(top_srcdir) -I$(includedir)
include Makefile.common
plugindir = @plugindir@
plugin_LTLIBRARIES = opcua.la
opcua_la_SOURCES = \
plugin.c \
moduleinfo.h \
$(DISSECTOR_SRC) \
$(DISSECTOR_INCLUDES)
opcua_la_LDFLAGS = -module -avoid-version
opcua_la_LIBADD = @PLUGIN_LIBS@
# Libs must be cleared, or else libtool won't create a shared module.
# If your module needs to be linked against any particular libraries,
# add them here.
LIBS =
#
# Build plugin.c, which contains the plugin version[] string, a
# function plugin_register() that calls the register routines for all
# protocols, and a function plugin_reg_handoff() that calls the handoff
# registration routines for all protocols.
#
# We do this by scanning sources. If that turns out to be too slow,
# maybe we could just require every .o file to have an register routine
# of a given name (packet-aarp.o -> proto_register_aarp, etc.).
#
# Formatting conventions: The name of the proto_register_* routines an
# proto_reg_handoff_* routines must start in column zero, or must be
# preceded only by "void " starting in column zero, and must not be
# inside #if.
#
# DISSECTOR_SRC is assumed to have all the files that need to be scanned.
#
# For some unknown reason, having a big "for" loop in the Makefile
# to scan all the files doesn't work with some "make"s; they seem to
# pass only the first few names in the list to the shell, for some
# reason.
#
# Therefore, we have a script to generate the plugin.c file.
# The shell script runs slowly, as multiple greps and seds are run
# for each input file; this is especially slow on Windows. Therefore,
# if Python is present (as indicated by PYTHON being defined), we run
# a faster Python script to do that work instead.
#
# The first argument is the directory in which the source files live.
# The second argument is "plugin", to indicate that we should build
# a plugin.c file for a plugin.
# All subsequent arguments are the files to scan.
#
plugin.c: $(DISSECTOR_SRC) $(top_srcdir)/tools/make-dissector-reg \
$(top_srcdir)/tools/make-dissector-reg.py
@if test -n $(PYTHON); then \
echo Making plugin.c with python ; \
$(PYTHON) $(top_srcdir)/tools/make-dissector-reg.py $(srcdir) \
plugin $(DISSECTOR_SRC) ; \
else \
echo Making plugin.c with shell script ; \
$(top_srcdir)/tools/make-dissector-reg $(srcdir) \
$(plugin_src) plugin $(DISSECTOR_SRC) ; \
fi
#
# Currently plugin.c can be included in the distribution because
# we always build all protocol dissectors. We used to have to check
# whether or not to build the snmp dissector. If we again need to
# variably build something, making plugin.c non-portable, uncomment
# the dist-hook line below.
#
# Oh, yuk. We don't want to include "plugin.c" in the distribution, as
# its contents depend on the configuration, and therefore we want it
# to be built when the first "make" is done; however, Automake insists
# on putting *all* source into the distribution.
#
# We work around this by having a "dist-hook" rule that deletes
# "plugin.c", so that "dist" won't pick it up.
#
#dist-hook:
# @rm -f $(distdir)/plugin.c
CLEANFILES = \
opcua \
*~
MAINTAINERCLEANFILES = \
Makefile.in \
plugin.c
EXTRA_DIST = \
Makefile.common \
Makefile.nmake

View File

@ -0,0 +1,41 @@
# Makefile.common for OpcUa plugin
# Contains the stuff from Makefile.am and Makefile.nmake that is
# a) common to both files and
# b) portable between both files
#
# $Id: Makefile.common,v 1.3 2007/02/08 11:29:50 gergap Exp $
#
# Adapted by Gerhard Gappmeier for OpcUa
# Wireshark - Network traffic analyzer
# By Gerald Combs <gerald@wireshark.org>
# Copyright 1998 Gerald Combs
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# the name of the plugin
PLUGIN_NAME = opcua
# the dissector sources (without any helpers)
DISSECTOR_SRC = \
opcua.c \
ua_transport_layer.c \
ua_security_layer.c \
ua_application_layer.c \
opcua_serviceparser.c \
opcua_complextypeparser.c \
opcua_enumparser.c \
opcua_simpletypes.c \
opcua_servicetable.c \
opcua_hfindeces.c

View File

@ -0,0 +1,79 @@
# Makefile.nmake
# nmake file for OpcUa plugin
#
# $Id: Makefile.nmake,v 1.1.1.1 2006/07/12 09:17:41 gergap Exp $
#
include ..\..\config.nmake
############### no need to modify below this line #########
include Makefile.common
CFLAGS=/DHAVE_CONFIG_H /I../.. /I../../wiretap $(GLIB_CFLAGS) \
/I$(PCAP_DIR)\include -D_U_="" $(LOCAL_CFLAGS)
LDFLAGS = /NOLOGO /INCREMENTAL:no /MACHINE:I386 $(LOCAL_LDFLAGS)
!IFDEF ENABLE_LIBWIRESHARK
LINK_PLUGIN_WITH=..\..\epan\libwireshark.lib ..\..\epan\dissectors\dissectors.lib
CFLAGS=/DHAVE_WIN32_LIBWIRESHARK_LIB /D_NEED_VAR_IMPORT_ $(CFLAGS)
DISSECTOR_OBJECTS = $(DISSECTOR_SRC:.c=.obj)
OBJECTS=$(DISSECTOR_OBJECTS) plugin.obj
opcua.dll opcua.exp opcua.lib : $(OBJECTS) $(LINK_PLUGIN_WITH)
link -dll /out:opcua.dll $(LDFLAGS) $(OBJECTS) $(LINK_PLUGIN_WITH) \
$(GLIB_LIBS)
#
# Build plugin.c, which contains the plugin version[] string, a
# function plugin_register() that calls the register routines for all
# protocols, and a function plugin_reg_handoff() that calls the handoff
# registration routines for all protocols.
#
# We do this by scanning sources. If that turns out to be too slow,
# maybe we could just require every .o file to have an register routine
# of a given name (packet-aarp.o -> proto_register_aarp, etc.).
#
# Formatting conventions: The name of the proto_register_* routines an
# proto_reg_handoff_* routines must start in column zero, or must be
# preceded only by "void " starting in column zero, and must not be
# inside #if.
#
# DISSECTOR_SRC is assumed to have all the files that need to be scanned.
#
# For some unknown reason, having a big "for" loop in the Makefile
# to scan all the files doesn't work with some "make"s; they seem to
# pass only the first few names in the list to the shell, for some
# reason.
#
# Therefore, we have a script to generate the plugin.c file.
# The shell script runs slowly, as multiple greps and seds are run
# for each input file; this is especially slow on Windows. Therefore,
# if Python is present (as indicated by PYTHON being defined), we run
# a faster Python script to do that work instead.
#
# The first argument is the directory in which the source files live.
# The second argument is "plugin", to indicate that we should build
# a plugin.c file for a plugin.
# All subsequent arguments are the files to scan.
#
plugin.c: $(DISSECTOR_SRC)
!IFDEF PYTHON
@echo Making plugin.c (using python)
@$(PYTHON) ../../tools/make-dissector-reg.py . plugin $(DISSECTOR_SRC)
!ELSE
@echo Making plugin.c (using sh)
@$(SH) ../../tools/make-dissector-reg . plugin $(DISSECTOR_SRC)
!ENDIF
!ENDIF
clean:
rm -f $(OBJECTS) opcua.dll opcua.exp opcua.lib *.pdb
distclean: clean
maintainer-clean: distclean

58
plugins/opcua/README Normal file
View File

@ -0,0 +1,58 @@
OpcUa Plugin:
=============
This plugin implements the dissection of the OpcUa Binary Protocol.
Author: Gerhard Gappmeier
ascolab GmbH
http://www.ascolab.com
Overview:
=========
OpcUa (OPC Unified Architecture) is a vendor and platform independent
protocol for automation technology. It is the successor of the
COM/DCOM based specifications OPC DA, OPC Alarm & Events, OPC HDA, etc.
It unifies all this technologies into a single protocol.
The specification describes abstract services that are independent
of the underlying protocol. For now there exist protocol mappings
to a Binary TCP based protocol and a SOAP based Webservice.
Also a hybrid version will be available where the Binary messages are transported
by a single webservice command called "Invoke".
More information about the technology you can find on
http://www.ascolab.com/index.php?file=ua&lang=en.
Protocol Mappings:
==================
Binary (TCP): The fastest and most flexible version (small footprint, no XML and SOAP necessary)
can easily be tunneled (SSH, IPSEC, etc.), redirected, ...
SOAP version: Easy to implement with verious tools like .Net, JAVA, gSOAP, etc.
Better to communicate through firewalls via HTTP.
SOAP with Binary Attchment: Combines the advantages of both.
The messages are encoded as Binary, and transported via SOAP as binary
attachment.
The OPC Foundation offers a free Opc Ua stack implementation in ANSI C
for all members. This stack implements the binary protocol as well
as the SOAP version. It's easily portable to different kinds of operating
systems from embedded devices to servers.
This makes it easy to implement Opc Ua applications based on this stack
and it is expected that the binary protocol will be the most used
protocol.
Nevertheless it's free to everbody to implement an own stack according
to the specification. An own implementation of the SOAP version
should be easy with the various SOAP toolkits.
For more information see http://www.opcfoundation.org
Known limitations:
==================
* In this version the security layer contains only dummy data.
The plugin decodes the transport layer, skips the security dummy data
and decodes the application layer.
Security implementation will follow when it has been implemented in the
Opc Ua stack.

View File

@ -0,0 +1,17 @@
/* Included *after* config.h, in order to re-define these macros */
#ifdef PACKAGE
#undef PACKAGE
#endif
/* Name of package */
#define PACKAGE "opcua"
#ifdef VERSION
#undef VERSION
#endif
/* Version number of package */
#define VERSION "0.0.1"

255
plugins/opcua/opcua.c Normal file
View File

@ -0,0 +1,255 @@
/******************************************************************************
** $Id: opcua.c,v 1.5 2007/02/08 11:29:45 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Protocol Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include <epan/emem.h>
#include <epan/dissectors/packet-tcp.h>
#include <epan/prefs.h>
#include "ua_transport_layer.h"
#include "ua_security_layer.h"
#include "ua_application_layer.h"
#include "opcua_complextypeparser.h"
#include "opcua_serviceparser.h"
#include "opcua_enumparser.h"
#include "opcua_simpletypes.h"
#include "opcua_hfindeces.h"
/* forward reference */
void proto_register_opcua (void);
void proto_reg_handoff_opcua (void);
static void dissect_opcua(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
static void dissect_opcua_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
/* declare parse function pointer */
typedef void (*FctParse)(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
static int proto_opcua = -1;
/** Official IANA registered port for OPC UA Binary Protocol. */
static int global_opcua_port = 4840;
static dissector_handle_t opcua_handle;
/** subtree types */
gint ett_opcua_transport = -1;
gint ett_opcua_extensionobject = -1;
gint ett_opcua_nodeid = -1;
/** OpcUa Transport Message Types */
enum MessageType
{
MSG_HELLO = 0,
MSG_ACKNOWLEDGE,
MSG_DISCONNECT,
MSG_DATA_LAST_CHUNK,
MSG_DATA,
MSG_ABORT,
MSG_ERROR,
MSG_INVALID,
MSG_UNKNOWN
};
/** OpcUa Transport Message Type Names */
static char* g_szMessageTypes[] =
{
"Hello message",
"Acknowledge message",
"Disconnect message",
"Data message, last chunk in message.",
"Data message, further chunks must follow.",
"Abort message",
"Error message",
"Invalid message",
"Unknown message"
};
/** Setup protocol subtree array */
static gint *ett[] =
{
&ett_opcua_transport,
&ett_opcua_extensionobject,
&ett_opcua_nodeid,
};
/** plugin entry functions.
* This registers the OpcUa protocol.
*/
void proto_register_opcua(void)
{
module_t *opcua_module;
if (proto_opcua == -1)
{
proto_opcua = proto_register_protocol(
"OpcUa Binary Protocol", /* name */
"OpcUa", /* short name */
"opcua" /* abbrev */
);
}
opcua_module = prefs_register_protocol(proto_opcua, proto_reg_handoff_opcua);
registerTransportLayerTypes(proto_opcua);
registerSecurityLayerTypes(proto_opcua);
registerApplicationLayerTypes(proto_opcua);
registerSimpleTypes(proto_opcua);
registerEnumTypes(proto_opcua);
registerComplexTypes();
registerServiceTypes();
registerFieldTypes(proto_opcua);
proto_register_subtree_array(ett, array_length(ett));
}
/** Register sub protocol.
* For TCP port 4840.
*/
void proto_reg_handoff_opcua(void)
{
static int Initialized=FALSE;
if (!Initialized)
{
opcua_handle = create_dissector_handle(dissect_opcua, proto_opcua);
dissector_add("tcp.port", global_opcua_port, opcua_handle);
}
}
/** header length that is needed to compute
* the pdu length.
* @see get_opcua_message_len
*/
#define FRAME_HEADER_LEN 8
/** returns the length of an OpcUa message.
* This function reads the length information from
* the transport header.
*/
static guint get_opcua_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset)
{
gint32 plen;
/* the message length starts at offset 4 */
plen = tvb_get_letohl(tvb, offset + 4);
return plen;
}
/** The main OpcUa dissector functions.
* It uses tcp_dissect_pdus from packet-tcp.h
* to reassemble the TCP data.
*/
static void dissect_opcua(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
tcp_dissect_pdus(tvb, pinfo, tree, TRUE, FRAME_HEADER_LEN,
get_opcua_message_len, dissect_opcua_message);
}
/** The OpcUa message dissector.
* This method dissects full OpcUa messages.
* It gets only called with reassembled data
* from tcp_dissect_pdus.
*/
static void dissect_opcua_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
FctParse pfctParse = NULL;
enum MessageType msgtype = MSG_INVALID;
if (check_col(pinfo->cinfo, COL_PROTOCOL))
{
col_set_str(pinfo->cinfo, COL_PROTOCOL, "OpcUa");
}
/* parse message type */
if (tvb->real_data[0] == 'U' && tvb->real_data[1] == 'A')
{
if (tvb->real_data[2] == 'T')
{
switch(tvb->real_data[3])
{
case 'H': msgtype = MSG_HELLO;
pfctParse = parseHello;
break;
case 'A': msgtype = MSG_ACKNOWLEDGE;
pfctParse = parseAcknowledge;
break;
case 'D': msgtype = MSG_DISCONNECT;
pfctParse = parseDisconnect;
break;
default: msgtype = MSG_INVALID;
break;
}
}
else if (tvb->real_data[2] == 'M')
{
switch(tvb->real_data[3])
{
case 'G': msgtype = MSG_DATA_LAST_CHUNK;
pfctParse = parseData;
break;
case 'C': msgtype = MSG_DATA;
pfctParse = parseData;
break;
case 'A': msgtype = MSG_ABORT;
pfctParse = parseAbort;
break;
case 'E': msgtype = MSG_ERROR;
pfctParse = parseError;
break;
default: msgtype = MSG_INVALID;
break;
}
}
}
else
{
msgtype = MSG_UNKNOWN;
}
/* Clear out stuff in the info column */
if(check_col(pinfo->cinfo, COL_INFO))
{
col_set_str(pinfo->cinfo, COL_INFO, g_szMessageTypes[msgtype]);
}
if (tree && pfctParse)
{
gint offset = 0;
/* we are being asked for details */
proto_item *ti = NULL;
proto_tree *transport_tree = NULL;
ti = proto_tree_add_item(tree, proto_opcua, tvb, 0, -1, FALSE);
transport_tree = proto_item_add_subtree(ti, ett_opcua_transport);
/* call the transport message dissector */
(*pfctParse)(transport_tree, tvb, &offset);
}
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,153 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Complex Type Parser
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
void parseReferenceNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseObjectNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseObjectTypeNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseVariableNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseVariableTypeNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReferenceTypeNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMethodNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseViewNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDataTypeNode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseUriTableEntry(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNodeSet(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseArgument(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseStatus(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBaseEvent(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSecurityPolicy(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseUserTokenPolicy(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseServerDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEndpointDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEndpointConfiguration(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseUserIdentityToken(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseUserNameIdentityToken(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseX509IdentityToken(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseWssIdentityToken(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSupportedProfile(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBuildInfo(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSoftwareCertificate(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSignedSoftwareCertificate(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNodeAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseObjectAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseObjectTypeAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseVariableAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseVariableTypeAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReferenceTypeAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMethodAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseViewAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAddNodesItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAddReferencesItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDeleteNodesItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDeleteReferencesItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseRedundantServerDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSamplingRateDiagnosticsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseServerDiagnosticsSummaryDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseServerStatusDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseServiceCounterDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSessionDiagnosticsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSessionSecurityDiagnosticsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSubscriptionDiagnosticsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseRange(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEUInformation(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAnnotation(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBaseStructureDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDerivedStructureDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseScalarValuesDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseArrayValuesDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseRequestHeader(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseResponseHeader(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseServiceFault(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseComplexTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBaseTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDerivedTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseScalarTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseArrayTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseCompositeTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseRegisteredServer(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseChannelSecurityToken(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSignatureData(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAddNodesResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBrowsePropertiesPropertyResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBrowsePropertiesResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReferenceDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseViewDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseBrowsePath(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseTranslateBrowsePathResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAttributeDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNodeTypeDescription(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseQueryDataSet(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNodeReference(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseContentFilterElement(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseContentFilter(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseFilterOperand(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseElementOperand(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseLiteralOperand(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseAttributeOperand(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parsePropertyOperand(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseContentFilterResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseQueryResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReadValueId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseHistoryReadValueId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseHistoryReadResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoringFilter(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEventFilter(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReadEventDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReadRawModifiedDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReadProcessedDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseReadAtTimeDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseHistoryData(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEventFieldList(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEventNotification(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseHistoryEvent(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseWriteValue(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseInsertReplaceDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseInsertEventDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDeleteRawModifiedDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDeleteAtTimeDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDeleteEventDetails(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseHistoryUpdateResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseCallRequestItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseCallResultItem(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDataChangeFilter(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoringFilterResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseEventFilterResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoringAttributes(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoredItemCreateRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoredItemCreateResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoredItemModifyRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoredItemModifyResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseSubscriptionAcknowledgement(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNotificationMessage(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseMonitoredItemNotification(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDataChangeNotification(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseTransferResult(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void registerComplexTypes();

View File

@ -0,0 +1,418 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Enum Type Parser
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "opcua_enumparser.h"
/** NodeClass enum table */
static const value_string g_NodeClassTable[] = {
{ 0, "Node" },
{ 1, "Object" },
{ 2, "Variable" },
{ 4, "Method" },
{ 8, "ObjectType" },
{ 16, "VariableType" },
{ 32, "ReferenceType" },
{ 64, "DataType" },
{ 128, "View" },
{ 0, NULL }
};
static int hf_opcua_NodeClass = -1;
void parseNodeClass(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_NodeClass, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** IdType enum table */
static const value_string g_IdTypeTable[] = {
{ 0, "Numeric" },
{ 1, "String" },
{ 2, "Uri" },
{ 3, "Guid" },
{ 4, "Opaque" },
{ 0, NULL }
};
static int hf_opcua_IdType = -1;
void parseIdType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_IdType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** MessageSecurityMode enum table */
static const value_string g_MessageSecurityModeTable[] = {
{ 0, "None" },
{ 1, "Sign" },
{ 2, "SignAndEncrypt" },
{ 0, NULL }
};
static int hf_opcua_MessageSecurityMode = -1;
void parseMessageSecurityMode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_MessageSecurityMode, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** UserTokenType enum table */
static const value_string g_UserTokenTypeTable[] = {
{ 0, "Default" },
{ 1, "UserName" },
{ 2, "Certificate" },
{ 3, "IssuedToken" },
{ 0, NULL }
};
static int hf_opcua_UserTokenType = -1;
void parseUserTokenType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_UserTokenType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** ServerDescriptionType enum table */
static const value_string g_ServerDescriptionTypeTable[] = {
{ 0, "Standard" },
{ 1, "Discovery" },
{ 0, NULL }
};
static int hf_opcua_ServerDescriptionType = -1;
void parseServerDescriptionType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_ServerDescriptionType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** SecurityTokenRequestType enum table */
static const value_string g_SecurityTokenRequestTypeTable[] = {
{ 0, "Issue" },
{ 1, "Renew" },
{ 0, NULL }
};
static int hf_opcua_SecurityTokenRequestType = -1;
void parseSecurityTokenRequestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_SecurityTokenRequestType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** ComplianceLevel enum table */
static const value_string g_ComplianceLevelTable[] = {
{ 0, "Untested" },
{ 1, "Partial" },
{ 2, "SelfTested" },
{ 3, "Certified" },
{ 0, NULL }
};
static int hf_opcua_ComplianceLevel = -1;
void parseComplianceLevel(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_ComplianceLevel, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** RedundancySupport enum table */
static const value_string g_RedundancySupportTable[] = {
{ 1, "None" },
{ 2, "Cold" },
{ 3, "Warm" },
{ 4, "Hot" },
{ 0, NULL }
};
static int hf_opcua_RedundancySupport = -1;
void parseRedundancySupport(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_RedundancySupport, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** ServerState enum table */
static const value_string g_ServerStateTable[] = {
{ 1, "Running" },
{ 2, "Failed" },
{ 3, "NoConfiguration" },
{ 4, "Suspended" },
{ 5, "Shutdown" },
{ 6, "Test" },
{ 7, "CommunicationFault" },
{ 8, "Unknown" },
{ 0, NULL }
};
static int hf_opcua_ServerState = -1;
void parseServerState(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_ServerState, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** ExceptionDeviationType enum table */
static const value_string g_ExceptionDeviationTypeTable[] = {
{ 1, "AbsoluteValue" },
{ 2, "PercentOfRange" },
{ 3, "PercentOfValue" },
{ 0, NULL }
};
static int hf_opcua_ExceptionDeviationType = -1;
void parseExceptionDeviationType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_ExceptionDeviationType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** ColorsDataType enum table */
static const value_string g_ColorsDataTypeTable[] = {
{ 1, "Red" },
{ 2, "Orange" },
{ 3, "Yellow" },
{ 4, "Green" },
{ 5, "Blue" },
{ 6, "DarkBlue" },
{ 7, "Violet" },
{ 0, NULL }
};
static int hf_opcua_ColorsDataType = -1;
void parseColorsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_ColorsDataType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** DiagnosticsMasks enum table */
static const value_string g_DiagnosticsMasksTable[] = {
{ 1, "ServiceSymbolicId" },
{ 2, "ServiceLocalizedText" },
{ 4, "ServiceAdditionalInfo" },
{ 8, "ServiceInnerStatusCode" },
{ 16, "ServiceInnerDiagnostics" },
{ 3, "ServiceSymbolicIdAndText" },
{ 15, "ServiceNoInnerStatus" },
{ 31, "ServiceAll" },
{ 32, "OperationSymbolicId" },
{ 64, "OperationLocalizedText" },
{ 128, "OperationAdditionalInfo" },
{ 256, "OperationInnerStatusCode" },
{ 512, "OperationInnerDiagnostics" },
{ 96, "OperationSymbolicIdAndText" },
{ 224, "OperationNoInnerStatus" },
{ 992, "OperationAll" },
{ 33, "SymbolicId" },
{ 66, "LocalizedText" },
{ 132, "AdditionalInfo" },
{ 264, "InnerStatusCode" },
{ 528, "InnerDiagnostics" },
{ 99, "SymbolicIdAndText" },
{ 239, "NoInnerStatus" },
{ 1023, "All" },
{ 0, NULL }
};
static int hf_opcua_DiagnosticsMasks = -1;
void parseDiagnosticsMasks(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_DiagnosticsMasks, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** EnumeratedTestType enum table */
static const value_string g_EnumeratedTestTypeTable[] = {
{ 1, "Red" },
{ 4, "Yellow" },
{ 5, "Green" },
{ 0, NULL }
};
static int hf_opcua_EnumeratedTestType = -1;
void parseEnumeratedTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_EnumeratedTestType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** BrowseDirection enum table */
static const value_string g_BrowseDirectionTable[] = {
{ 1, "Forward" },
{ 2, "Inverse" },
{ 3, "Both" },
{ 0, NULL }
};
static int hf_opcua_BrowseDirection = -1;
void parseBrowseDirection(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_BrowseDirection, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** FilterOperator enum table */
static const value_string g_FilterOperatorTable[] = {
{ 1, "Equals" },
{ 2, "IsNull" },
{ 3, "GreaterThan" },
{ 4, "LessThan" },
{ 5, "GreaterThanOrEqual" },
{ 6, "LessThanOrEqual" },
{ 7, "Like" },
{ 8, "Not" },
{ 9, "Between" },
{ 10, "InList" },
{ 11, "And" },
{ 12, "Or" },
{ 13, "InView" },
{ 14, "OfType" },
{ 15, "RelatedTo" },
{ 0, NULL }
};
static int hf_opcua_FilterOperator = -1;
void parseFilterOperator(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_FilterOperator, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** TimestampsToReturn enum table */
static const value_string g_TimestampsToReturnTable[] = {
{ 1, "Source" },
{ 2, "Server" },
{ 3, "Both" },
{ 4, "Neither" },
{ 0, NULL }
};
static int hf_opcua_TimestampsToReturn = -1;
void parseTimestampsToReturn(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_TimestampsToReturn, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** MonitoringMode enum table */
static const value_string g_MonitoringModeTable[] = {
{ 0, "Disabled" },
{ 1, "Sampling" },
{ 2, "Reporting" },
{ 0, NULL }
};
static int hf_opcua_MonitoringMode = -1;
void parseMonitoringMode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_MonitoringMode, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** DataChangeTrigger enum table */
static const value_string g_DataChangeTriggerTable[] = {
{ 0, "Status" },
{ 1, "StatusValue" },
{ 2, "StatusValueTimestamp" },
{ 0, NULL }
};
static int hf_opcua_DataChangeTrigger = -1;
void parseDataChangeTrigger(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_DataChangeTrigger, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** DeadbandType enum table */
static const value_string g_DeadbandTypeTable[] = {
{ 0, "None" },
{ 1, "Absolute" },
{ 2, "Percentage" },
{ 0, NULL }
};
static int hf_opcua_DeadbandType = -1;
void parseDeadbandType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_tree_add_item(tree, hf_opcua_DeadbandType, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
/** header field definitions */
static hf_register_info hf[] =
{
{ &hf_opcua_NodeClass,
{ "NodeClass", "", FT_UINT32, BASE_HEX, VALS(g_NodeClassTable), 0x0, "", HFILL }
},
{ &hf_opcua_IdType,
{ "IdType", "", FT_UINT32, BASE_HEX, VALS(g_IdTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_MessageSecurityMode,
{ "MessageSecurityMode", "", FT_UINT32, BASE_HEX, VALS(g_MessageSecurityModeTable), 0x0, "", HFILL }
},
{ &hf_opcua_UserTokenType,
{ "UserTokenType", "", FT_UINT32, BASE_HEX, VALS(g_UserTokenTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_ServerDescriptionType,
{ "ServerDescriptionType", "", FT_UINT32, BASE_HEX, VALS(g_ServerDescriptionTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_SecurityTokenRequestType,
{ "SecurityTokenRequestType", "", FT_UINT32, BASE_HEX, VALS(g_SecurityTokenRequestTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_ComplianceLevel,
{ "ComplianceLevel", "", FT_UINT32, BASE_HEX, VALS(g_ComplianceLevelTable), 0x0, "", HFILL }
},
{ &hf_opcua_RedundancySupport,
{ "RedundancySupport", "", FT_UINT32, BASE_HEX, VALS(g_RedundancySupportTable), 0x0, "", HFILL }
},
{ &hf_opcua_ServerState,
{ "ServerState", "", FT_UINT32, BASE_HEX, VALS(g_ServerStateTable), 0x0, "", HFILL }
},
{ &hf_opcua_ExceptionDeviationType,
{ "ExceptionDeviationType", "", FT_UINT32, BASE_HEX, VALS(g_ExceptionDeviationTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_ColorsDataType,
{ "ColorsDataType", "", FT_UINT32, BASE_HEX, VALS(g_ColorsDataTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_DiagnosticsMasks,
{ "DiagnosticsMasks", "", FT_UINT32, BASE_HEX, VALS(g_DiagnosticsMasksTable), 0x0, "", HFILL }
},
{ &hf_opcua_EnumeratedTestType,
{ "EnumeratedTestType", "", FT_UINT32, BASE_HEX, VALS(g_EnumeratedTestTypeTable), 0x0, "", HFILL }
},
{ &hf_opcua_BrowseDirection,
{ "BrowseDirection", "", FT_UINT32, BASE_HEX, VALS(g_BrowseDirectionTable), 0x0, "", HFILL }
},
{ &hf_opcua_FilterOperator,
{ "FilterOperator", "", FT_UINT32, BASE_HEX, VALS(g_FilterOperatorTable), 0x0, "", HFILL }
},
{ &hf_opcua_TimestampsToReturn,
{ "TimestampsToReturn", "", FT_UINT32, BASE_HEX, VALS(g_TimestampsToReturnTable), 0x0, "", HFILL }
},
{ &hf_opcua_MonitoringMode,
{ "MonitoringMode", "", FT_UINT32, BASE_HEX, VALS(g_MonitoringModeTable), 0x0, "", HFILL }
},
{ &hf_opcua_DataChangeTrigger,
{ "DataChangeTrigger", "", FT_UINT32, BASE_HEX, VALS(g_DataChangeTriggerTable), 0x0, "", HFILL }
},
{ &hf_opcua_DeadbandType,
{ "DeadbandType", "", FT_UINT32, BASE_HEX, VALS(g_DeadbandTypeTable), 0x0, "", HFILL }
}
};
/** Register enum types. */
void registerEnumTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
}

View File

@ -0,0 +1,51 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Enum Type Parser
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
void parseNodeClass(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseIdType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseMessageSecurityMode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseUserTokenType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseServerDescriptionType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSecurityTokenRequestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseComplianceLevel(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseRedundancySupport(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseServerState(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseExceptionDeviationType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseColorsDataType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDiagnosticsMasks(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseEnumeratedTestType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowseDirection(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseFilterOperator(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTimestampsToReturn(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseMonitoringMode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDataChangeTrigger(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeadbandType(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void registerEnumTypes(int proto);

View File

@ -0,0 +1,590 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: This file contains protocol field information.
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
int hf_opcua_TestId = -1;
int hf_opcua_Iteration = -1;
int hf_opcua_ServerUris = -1;
int hf_opcua_ProfileUris = -1;
int hf_opcua_ClientCertificate = -1;
int hf_opcua_SecureChannelId = -1;
int hf_opcua_SecurityPolicyUri = -1;
int hf_opcua_ClientNonce = -1;
int hf_opcua_RequestedLifetime = -1;
int hf_opcua_ServerCertificate = -1;
int hf_opcua_ServerNonce = -1;
int hf_opcua_ClientName = -1;
int hf_opcua_RequestedSessionTimeout = -1;
int hf_opcua_SessionId = -1;
int hf_opcua_RevisedSessionTimeout = -1;
int hf_opcua_LocaleIds = -1;
int hf_opcua_CertificateResults = -1;
int hf_opcua_SequenceNumber = -1;
int hf_opcua_Results = -1;
int hf_opcua_MaxResultsToReturn = -1;
int hf_opcua_IncludeSubtypes = -1;
int hf_opcua_NodeClassMask = -1;
int hf_opcua_ContinuationPoint = -1;
int hf_opcua_ReleaseContinuationPoint = -1;
int hf_opcua_RevisedContinuationPoint = -1;
int hf_opcua_MaxDescriptionsToReturn = -1;
int hf_opcua_MaxReferencesToReturn = -1;
int hf_opcua_MaxReferencedNodesToReturn = -1;
int hf_opcua_MaxTime = -1;
int hf_opcua_MaxAge = -1;
int hf_opcua_ReleaseContinuationPoints = -1;
int hf_opcua_SubscriptionId = -1;
int hf_opcua_MonitoredItemIds = -1;
int hf_opcua_TriggeringItemId = -1;
int hf_opcua_LinksToAdd = -1;
int hf_opcua_LinksToRemove = -1;
int hf_opcua_AddResults = -1;
int hf_opcua_RemoveResults = -1;
int hf_opcua_RequestedPublishingInterval = -1;
int hf_opcua_RequestedLifetimeCounter = -1;
int hf_opcua_RequestedMaxKeepAliveCount = -1;
int hf_opcua_PublishingEnabled = -1;
int hf_opcua_Priority = -1;
int hf_opcua_RevisedPublishingInterval = -1;
int hf_opcua_RevisedLifetimeCounter = -1;
int hf_opcua_RevisedMaxKeepAliveCount = -1;
int hf_opcua_SubscriptionIds = -1;
int hf_opcua_AvailableSequenceNumbers = -1;
int hf_opcua_MoreNotifications = -1;
int hf_opcua_RetransmitSequenceNumber = -1;
int hf_opcua_IsInverse = -1;
int hf_opcua_ServerIndex = -1;
int hf_opcua_NodeClass = -1;
int hf_opcua_EventNotifier = -1;
int hf_opcua_IsAbstract = -1;
int hf_opcua_ArraySize = -1;
int hf_opcua_AccessLevel = -1;
int hf_opcua_UserAccessLevel = -1;
int hf_opcua_MinimumSamplingInterval = -1;
int hf_opcua_Historizing = -1;
int hf_opcua_Symmetric = -1;
int hf_opcua_Executable = -1;
int hf_opcua_UserExecutable = -1;
int hf_opcua_ContainsNoLoops = -1;
int hf_opcua_Index = -1;
int hf_opcua_Uri = -1;
int hf_opcua_Name = -1;
int hf_opcua_StatusCode = -1;
int hf_opcua_EventId = -1;
int hf_opcua_SourceName = -1;
int hf_opcua_Time = -1;
int hf_opcua_ReceiveTime = -1;
int hf_opcua_Severity = -1;
int hf_opcua_Digest = -1;
int hf_opcua_SymmetricSignature = -1;
int hf_opcua_SymmetricKeyWrap = -1;
int hf_opcua_SymmetricEncryption = -1;
int hf_opcua_SymmetricKeyLength = -1;
int hf_opcua_AsymmetricSignature = -1;
int hf_opcua_AsymmetricKeyWrap = -1;
int hf_opcua_AsymmetricEncryption = -1;
int hf_opcua_MinimumAsymmetricKeyLength = -1;
int hf_opcua_MaximumAsymmetricKeyLength = -1;
int hf_opcua_DerivedKey = -1;
int hf_opcua_DerivedEncryptionKeyLength = -1;
int hf_opcua_DerivedSignatureKeyLength = -1;
int hf_opcua_IssuerType = -1;
int hf_opcua_IssuerUrl = -1;
int hf_opcua_ServerUri = -1;
int hf_opcua_DiscoveryUrls = -1;
int hf_opcua_EndpointUrl = -1;
int hf_opcua_SupportedProfiles = -1;
int hf_opcua_SendTimeout = -1;
int hf_opcua_OperationTimeout = -1;
int hf_opcua_UseBinaryEncoding = -1;
int hf_opcua_MaxMessageSize = -1;
int hf_opcua_MaxArrayLength = -1;
int hf_opcua_MaxStringLength = -1;
int hf_opcua_UserName = -1;
int hf_opcua_Password = -1;
int hf_opcua_HashAlgorithm = -1;
int hf_opcua_CertificateData = -1;
int hf_opcua_TokenData = -1;
int hf_opcua_ProfileUri = -1;
int hf_opcua_ProfileName = -1;
int hf_opcua_ApplicationUri = -1;
int hf_opcua_ManufacturerName = -1;
int hf_opcua_ApplicationName = -1;
int hf_opcua_SoftwareVersion = -1;
int hf_opcua_BuildNumber = -1;
int hf_opcua_BuildDate = -1;
int hf_opcua_IssuedBy = -1;
int hf_opcua_IssuedDate = -1;
int hf_opcua_ExpirationDate = -1;
int hf_opcua_ApplicationCertificate = -1;
int hf_opcua_IssuerCertificateThumbprint = -1;
int hf_opcua_IssuerSignatureAlgorithm = -1;
int hf_opcua_IssuerSignature = -1;
int hf_opcua_IsForward = -1;
int hf_opcua_TargetServerUri = -1;
int hf_opcua_TargetNodeClass = -1;
int hf_opcua_DeleteTargetReferences = -1;
int hf_opcua_ServerId = -1;
int hf_opcua_ServiceLevel = -1;
int hf_opcua_SamplingRate = -1;
int hf_opcua_SamplingErrorCount = -1;
int hf_opcua_SampledMonitoredItemsCount = -1;
int hf_opcua_MaxSampledMonitoredItemsCount = -1;
int hf_opcua_DisabledMonitoredItemsSamplingCount = -1;
int hf_opcua_ServerViewCount = -1;
int hf_opcua_CurrentSessionCount = -1;
int hf_opcua_CumulatedSessionCount = -1;
int hf_opcua_SecurityRejectedSessionCount = -1;
int hf_opcua_RejectSessionCount = -1;
int hf_opcua_SessionTimeoutCount = -1;
int hf_opcua_SessionAbortCount = -1;
int hf_opcua_SamplingRateCount = -1;
int hf_opcua_PublishingRateCount = -1;
int hf_opcua_CurrentSubscriptionCount = -1;
int hf_opcua_CumulatedSubscriptionCount = -1;
int hf_opcua_SecurityRejectedRequestsCount = -1;
int hf_opcua_RejectedRequestsCount = -1;
int hf_opcua_StartTime = -1;
int hf_opcua_CurrentTime = -1;
int hf_opcua_TotalCount = -1;
int hf_opcua_UnauthorizedCount = -1;
int hf_opcua_ErrorCount = -1;
int hf_opcua_ActualSessionTimeout = -1;
int hf_opcua_ClientConnectionTime = -1;
int hf_opcua_ClientLastContactTime = -1;
int hf_opcua_CurrentSubscriptionsCount = -1;
int hf_opcua_CurrentMonitoredItemsCount = -1;
int hf_opcua_CurrentPublishRequestsInQueue = -1;
int hf_opcua_CurrentPublishTimerExpirations = -1;
int hf_opcua_KeepAliveCount = -1;
int hf_opcua_CurrentRepublishRequestsInQueue = -1;
int hf_opcua_MaxRepublishRequestsInQueue = -1;
int hf_opcua_RepublishCounter = -1;
int hf_opcua_PublishingCount = -1;
int hf_opcua_PublishingQueueOverflowCount = -1;
int hf_opcua_ClientUserIdOfSession = -1;
int hf_opcua_ClientUserIdHistory = -1;
int hf_opcua_AuthenticationMechanism = -1;
int hf_opcua_Encoding = -1;
int hf_opcua_TransportProtocol = -1;
int hf_opcua_SecurityPolicy = -1;
int hf_opcua_PublishingInterval = -1;
int hf_opcua_MaxKeepAliveCount = -1;
int hf_opcua_ModifyCount = -1;
int hf_opcua_EnableCount = -1;
int hf_opcua_DisableCount = -1;
int hf_opcua_RepublishRequestCount = -1;
int hf_opcua_RepublishMessageRequestCount = -1;
int hf_opcua_RepublishMessageCount = -1;
int hf_opcua_TransferRequestCount = -1;
int hf_opcua_TransferredToAltClientCount = -1;
int hf_opcua_TransferredToSameClientCount = -1;
int hf_opcua_PublishRequestCount = -1;
int hf_opcua_DataChangeNotificationsCount = -1;
int hf_opcua_EventNotificationsCount = -1;
int hf_opcua_NotificationsCount = -1;
int hf_opcua_LateStateCount = -1;
int hf_opcua_KeepAliveStateCount = -1;
int hf_opcua_Low = -1;
int hf_opcua_High = -1;
int hf_opcua_NamespaceUri = -1;
int hf_opcua_UnitId = -1;
int hf_opcua_Message = -1;
int hf_opcua_AnnotationTime = -1;
int hf_opcua_Id = -1;
int hf_opcua_Description = -1;
int hf_opcua_Timestamp = -1;
int hf_opcua_Boolean = -1;
int hf_opcua_SByte = -1;
int hf_opcua_Byte = -1;
int hf_opcua_Int16 = -1;
int hf_opcua_UInt16 = -1;
int hf_opcua_Int32 = -1;
int hf_opcua_UInt32 = -1;
int hf_opcua_Int64 = -1;
int hf_opcua_UInt64 = -1;
int hf_opcua_Float = -1;
int hf_opcua_Double = -1;
int hf_opcua_String = -1;
int hf_opcua_DateTime = -1;
int hf_opcua_Guid = -1;
int hf_opcua_ByteString = -1;
int hf_opcua_XmlElement = -1;
int hf_opcua_RequestId = -1;
int hf_opcua_ReturnDiagnostics = -1;
int hf_opcua_AuditLogEntryId = -1;
int hf_opcua_TimeoutHint = -1;
int hf_opcua_ServiceResult = -1;
int hf_opcua_StringTable = -1;
int hf_opcua_Value1 = -1;
int hf_opcua_Value2 = -1;
int hf_opcua_Booleans = -1;
int hf_opcua_SBytes = -1;
int hf_opcua_Int16s = -1;
int hf_opcua_UInt16s = -1;
int hf_opcua_Int32s = -1;
int hf_opcua_UInt32s = -1;
int hf_opcua_Int64s = -1;
int hf_opcua_UInt64s = -1;
int hf_opcua_Floats = -1;
int hf_opcua_Doubles = -1;
int hf_opcua_Strings = -1;
int hf_opcua_DateTimes = -1;
int hf_opcua_Guids = -1;
int hf_opcua_ByteStrings = -1;
int hf_opcua_XmlElements = -1;
int hf_opcua_StatusCodes = -1;
int hf_opcua_SemaphoreFilePath = -1;
int hf_opcua_IsOnline = -1;
int hf_opcua_ChannelId = -1;
int hf_opcua_TokenId = -1;
int hf_opcua_CreatedAt = -1;
int hf_opcua_RevisedLifetime = -1;
int hf_opcua_Algorithm = -1;
int hf_opcua_Signature = -1;
int hf_opcua_PropertyStatusCode = -1;
int hf_opcua_ViewVersion = -1;
int hf_opcua_RelativePath = -1;
int hf_opcua_AttributeId = -1;
int hf_opcua_IndexRange = -1;
int hf_opcua_IncludeSubTypes = -1;
int hf_opcua_Alias = -1;
int hf_opcua_Result = -1;
int hf_opcua_IndexOfInvalidElement = -1;
int hf_opcua_AttributeStatusCodes = -1;
int hf_opcua_NumValuesPerNode = -1;
int hf_opcua_EndTime = -1;
int hf_opcua_IsReadModified = -1;
int hf_opcua_ReturnBounds = -1;
int hf_opcua_ResampleInterval = -1;
int hf_opcua_ReqTimes = -1;
int hf_opcua_ClientHandle = -1;
int hf_opcua_PerformInsert = -1;
int hf_opcua_PerformReplace = -1;
int hf_opcua_IsDeleteModified = -1;
int hf_opcua_OperationResult = -1;
int hf_opcua_InputArgumentResults = -1;
int hf_opcua_DeadbandType = -1;
int hf_opcua_DeadbandValue = -1;
int hf_opcua_SelectClauseResults = -1;
int hf_opcua_SamplingInterval = -1;
int hf_opcua_QueueSize = -1;
int hf_opcua_DiscardOldest = -1;
int hf_opcua_MonitoredItemId = -1;
int hf_opcua_RevisedSamplingInterval = -1;
int hf_opcua_RevisedQueueSize = -1;
int hf_opcua_MonitorItemId = -1;
int hf_opcua_PublishTime = -1;
int hf_opcua_AvailableSequenceNumbersRanges = -1;
/** header field definitions */
static hf_register_info hf[] =
{
{ &hf_opcua_TestId, { "TestId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Iteration, { "Iteration", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerUris, { "ServerUris", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ProfileUris, { "ProfileUris", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientCertificate, { "ClientCertificate", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SecureChannelId, { "SecureChannelId", "", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SecurityPolicyUri, { "SecurityPolicyUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientNonce, { "ClientNonce", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestedLifetime, { "RequestedLifetime", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerCertificate, { "ServerCertificate", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerNonce, { "ServerNonce", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientName, { "ClientName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestedSessionTimeout, { "RequestedSessionTimeout", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SessionId, { "SessionId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedSessionTimeout, { "RevisedSessionTimeout", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_LocaleIds, { "LocaleIds", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CertificateResults, { "CertificateResults", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SequenceNumber, { "SequenceNumber", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Results, { "Results", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxResultsToReturn, { "MaxResultsToReturn", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IncludeSubtypes, { "IncludeSubtypes", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_NodeClassMask, { "NodeClassMask", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ContinuationPoint, { "ContinuationPoint", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReleaseContinuationPoint, { "ReleaseContinuationPoint", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedContinuationPoint, { "RevisedContinuationPoint", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxDescriptionsToReturn, { "MaxDescriptionsToReturn", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxReferencesToReturn, { "MaxReferencesToReturn", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxReferencedNodesToReturn, { "MaxReferencedNodesToReturn", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxTime, { "MaxTime", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxAge, { "MaxAge", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReleaseContinuationPoints, { "ReleaseContinuationPoints", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SubscriptionId, { "SubscriptionId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MonitoredItemIds, { "MonitoredItemIds", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TriggeringItemId, { "TriggeringItemId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_LinksToAdd, { "LinksToAdd", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_LinksToRemove, { "LinksToRemove", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AddResults, { "AddResults", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RemoveResults, { "RemoveResults", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestedPublishingInterval, { "RequestedPublishingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestedLifetimeCounter, { "RequestedLifetimeCounter", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestedMaxKeepAliveCount, { "RequestedMaxKeepAliveCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishingEnabled, { "PublishingEnabled", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Priority, { "Priority", "", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedPublishingInterval, { "RevisedPublishingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedLifetimeCounter, { "RevisedLifetimeCounter", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedMaxKeepAliveCount, { "RevisedMaxKeepAliveCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SubscriptionIds, { "SubscriptionIds", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AvailableSequenceNumbers, { "AvailableSequenceNumbers", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MoreNotifications, { "MoreNotifications", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RetransmitSequenceNumber, { "RetransmitSequenceNumber", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsInverse, { "IsInverse", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerIndex, { "ServerIndex", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_NodeClass, { "NodeClass", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EventNotifier, { "EventNotifier", "", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsAbstract, { "IsAbstract", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ArraySize, { "ArraySize", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AccessLevel, { "AccessLevel", "", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UserAccessLevel, { "UserAccessLevel", "", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MinimumSamplingInterval, { "MinimumSamplingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Historizing, { "Historizing", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Symmetric, { "Symmetric", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Executable, { "Executable", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UserExecutable, { "UserExecutable", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ContainsNoLoops, { "ContainsNoLoops", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Index, { "Index", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Uri, { "Uri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Name, { "Name", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_StatusCode, { "StatusCode", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EventId, { "EventId", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SourceName, { "SourceName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Time, { "Time", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReceiveTime, { "ReceiveTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Severity, { "Severity", "", FT_UINT16, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Digest, { "Digest", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SymmetricSignature, { "SymmetricSignature", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SymmetricKeyWrap, { "SymmetricKeyWrap", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SymmetricEncryption, { "SymmetricEncryption", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SymmetricKeyLength, { "SymmetricKeyLength", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AsymmetricSignature, { "AsymmetricSignature", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AsymmetricKeyWrap, { "AsymmetricKeyWrap", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AsymmetricEncryption, { "AsymmetricEncryption", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MinimumAsymmetricKeyLength, { "MinimumAsymmetricKeyLength", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaximumAsymmetricKeyLength, { "MaximumAsymmetricKeyLength", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DerivedKey, { "DerivedKey", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DerivedEncryptionKeyLength, { "DerivedEncryptionKeyLength", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DerivedSignatureKeyLength, { "DerivedSignatureKeyLength", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuerType, { "IssuerType", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuerUrl, { "IssuerUrl", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerUri, { "ServerUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DiscoveryUrls, { "DiscoveryUrls", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EndpointUrl, { "EndpointUrl", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SupportedProfiles, { "SupportedProfiles", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SendTimeout, { "SendTimeout", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_OperationTimeout, { "OperationTimeout", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UseBinaryEncoding, { "UseBinaryEncoding", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxMessageSize, { "MaxMessageSize", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxArrayLength, { "MaxArrayLength", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxStringLength, { "MaxStringLength", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UserName, { "UserName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Password, { "Password", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_HashAlgorithm, { "HashAlgorithm", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CertificateData, { "CertificateData", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TokenData, { "TokenData", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ProfileUri, { "ProfileUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ProfileName, { "ProfileName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ApplicationUri, { "ApplicationUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ManufacturerName, { "ManufacturerName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ApplicationName, { "ApplicationName", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SoftwareVersion, { "SoftwareVersion", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_BuildNumber, { "BuildNumber", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_BuildDate, { "BuildDate", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuedBy, { "IssuedBy", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuedDate, { "IssuedDate", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ExpirationDate, { "ExpirationDate", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ApplicationCertificate, { "ApplicationCertificate", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuerCertificateThumbprint, { "IssuerCertificateThumbprint", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuerSignatureAlgorithm, { "IssuerSignatureAlgorithm", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IssuerSignature, { "IssuerSignature", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsForward, { "IsForward", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TargetServerUri, { "TargetServerUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TargetNodeClass, { "TargetNodeClass", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DeleteTargetReferences, { "DeleteTargetReferences", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerId, { "ServerId", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServiceLevel, { "ServiceLevel", "", FT_INT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SamplingRate, { "SamplingRate", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SamplingErrorCount, { "SamplingErrorCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SampledMonitoredItemsCount, { "SampledMonitoredItemsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxSampledMonitoredItemsCount, { "MaxSampledMonitoredItemsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DisabledMonitoredItemsSamplingCount, { "DisabledMonitoredItemsSamplingCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerViewCount, { "ServerViewCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentSessionCount, { "CurrentSessionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CumulatedSessionCount, { "CumulatedSessionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SecurityRejectedSessionCount, { "SecurityRejectedSessionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RejectSessionCount, { "RejectSessionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SessionTimeoutCount, { "SessionTimeoutCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SessionAbortCount, { "SessionAbortCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SamplingRateCount, { "SamplingRateCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishingRateCount, { "PublishingRateCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentSubscriptionCount, { "CurrentSubscriptionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CumulatedSubscriptionCount, { "CumulatedSubscriptionCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SecurityRejectedRequestsCount, { "SecurityRejectedRequestsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RejectedRequestsCount, { "RejectedRequestsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_StartTime, { "StartTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentTime, { "CurrentTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TotalCount, { "TotalCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UnauthorizedCount, { "UnauthorizedCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ErrorCount, { "ErrorCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ActualSessionTimeout, { "ActualSessionTimeout", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientConnectionTime, { "ClientConnectionTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientLastContactTime, { "ClientLastContactTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentSubscriptionsCount, { "CurrentSubscriptionsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentMonitoredItemsCount, { "CurrentMonitoredItemsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentPublishRequestsInQueue, { "CurrentPublishRequestsInQueue", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentPublishTimerExpirations, { "CurrentPublishTimerExpirations", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_KeepAliveCount, { "KeepAliveCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CurrentRepublishRequestsInQueue, { "CurrentRepublishRequestsInQueue", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxRepublishRequestsInQueue, { "MaxRepublishRequestsInQueue", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RepublishCounter, { "RepublishCounter", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishingCount, { "PublishingCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishingQueueOverflowCount, { "PublishingQueueOverflowCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientUserIdOfSession, { "ClientUserIdOfSession", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientUserIdHistory, { "ClientUserIdHistory", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AuthenticationMechanism, { "AuthenticationMechanism", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Encoding, { "Encoding", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TransportProtocol, { "TransportProtocol", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SecurityPolicy, { "SecurityPolicy", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishingInterval, { "PublishingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MaxKeepAliveCount, { "MaxKeepAliveCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ModifyCount, { "ModifyCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EnableCount, { "EnableCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DisableCount, { "DisableCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RepublishRequestCount, { "RepublishRequestCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RepublishMessageRequestCount, { "RepublishMessageRequestCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RepublishMessageCount, { "RepublishMessageCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TransferRequestCount, { "TransferRequestCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TransferredToAltClientCount, { "TransferredToAltClientCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TransferredToSameClientCount, { "TransferredToSameClientCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishRequestCount, { "PublishRequestCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DataChangeNotificationsCount, { "DataChangeNotificationsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EventNotificationsCount, { "EventNotificationsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_NotificationsCount, { "NotificationsCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_LateStateCount, { "LateStateCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_KeepAliveStateCount, { "KeepAliveStateCount", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Low, { "Low", "", FT_DOUBLE, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_High, { "High", "", FT_DOUBLE, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_NamespaceUri, { "NamespaceUri", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UnitId, { "UnitId", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Message, { "Message", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AnnotationTime, { "AnnotationTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Id, { "Id", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Description, { "Description", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Timestamp, { "Timestamp", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Boolean, { "Boolean", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SByte, { "SByte", "", FT_INT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Byte, { "Byte", "", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int16, { "Int16", "", FT_INT16, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt16, { "UInt16", "", FT_UINT16, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int32, { "Int32", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt32, { "UInt32", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int64, { "Int64", "", FT_INT64, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt64, { "UInt64", "", FT_UINT64, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Float, { "Float", "", FT_FLOAT, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Double, { "Double", "", FT_DOUBLE, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_String, { "String", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DateTime, { "DateTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Guid, { "Guid", "", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ByteString, { "ByteString", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_XmlElement, { "XmlElement", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RequestId, { "RequestId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReturnDiagnostics, { "ReturnDiagnostics", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AuditLogEntryId, { "AuditLogEntryId", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TimeoutHint, { "TimeoutHint", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServiceResult, { "ServiceResult", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_StringTable, { "StringTable", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Value1, { "Value1", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Value2, { "Value2", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Booleans, { "Booleans", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SBytes, { "SBytes", "", FT_INT8, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int16s, { "Int16s", "", FT_INT16, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt16s, { "UInt16s", "", FT_UINT16, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int32s, { "Int32s", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt32s, { "UInt32s", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Int64s, { "Int64s", "", FT_INT64, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_UInt64s, { "UInt64s", "", FT_UINT64, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Floats, { "Floats", "", FT_FLOAT, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Doubles, { "Doubles", "", FT_DOUBLE, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Strings, { "Strings", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DateTimes, { "DateTimes", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Guids, { "Guids", "", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ByteStrings, { "ByteStrings", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_XmlElements, { "XmlElements", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_StatusCodes, { "StatusCodes", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SemaphoreFilePath, { "SemaphoreFilePath", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsOnline, { "IsOnline", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ChannelId, { "ChannelId", "", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_TokenId, { "TokenId", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_CreatedAt, { "CreatedAt", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedLifetime, { "RevisedLifetime", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Algorithm, { "Algorithm", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Signature, { "Signature", "", FT_BYTES, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PropertyStatusCode, { "PropertyStatusCode", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ViewVersion, { "ViewVersion", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RelativePath, { "RelativePath", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AttributeId, { "AttributeId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IndexRange, { "IndexRange", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IncludeSubTypes, { "IncludeSubTypes", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Alias, { "Alias", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Result, { "Result", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IndexOfInvalidElement, { "IndexOfInvalidElement", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AttributeStatusCodes, { "AttributeStatusCodes", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_NumValuesPerNode, { "NumValuesPerNode", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_EndTime, { "EndTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsReadModified, { "IsReadModified", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReturnBounds, { "ReturnBounds", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ResampleInterval, { "ResampleInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ReqTimes, { "ReqTimes", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ClientHandle, { "ClientHandle", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PerformInsert, { "PerformInsert", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PerformReplace, { "PerformReplace", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_IsDeleteModified, { "IsDeleteModified", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_OperationResult, { "OperationResult", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_InputArgumentResults, { "InputArgumentResults", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DeadbandType, { "DeadbandType", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DeadbandValue, { "DeadbandValue", "", FT_DOUBLE, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SelectClauseResults, { "SelectClauseResults", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_SamplingInterval, { "SamplingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_QueueSize, { "QueueSize", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_DiscardOldest, { "DiscardOldest", "", FT_BOOLEAN, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MonitoredItemId, { "MonitoredItemId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedSamplingInterval, { "RevisedSamplingInterval", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_RevisedQueueSize, { "RevisedQueueSize", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_MonitorItemId, { "MonitorItemId", "", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_PublishTime, { "PublishTime", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_AvailableSequenceNumbersRanges, { "AvailableSequenceNumbersRanges", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } }
};
/** Register field types. */
void registerFieldTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
}

View File

@ -0,0 +1,307 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: This file contains protocol field handles.
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
extern int hf_opcua_TestId;
extern int hf_opcua_Iteration;
extern int hf_opcua_ServerUris;
extern int hf_opcua_ProfileUris;
extern int hf_opcua_ClientCertificate;
extern int hf_opcua_SecureChannelId;
extern int hf_opcua_SecurityPolicyUri;
extern int hf_opcua_ClientNonce;
extern int hf_opcua_RequestedLifetime;
extern int hf_opcua_ServerCertificate;
extern int hf_opcua_ServerNonce;
extern int hf_opcua_ClientName;
extern int hf_opcua_RequestedSessionTimeout;
extern int hf_opcua_SessionId;
extern int hf_opcua_RevisedSessionTimeout;
extern int hf_opcua_LocaleIds;
extern int hf_opcua_CertificateResults;
extern int hf_opcua_SequenceNumber;
extern int hf_opcua_Results;
extern int hf_opcua_MaxResultsToReturn;
extern int hf_opcua_IncludeSubtypes;
extern int hf_opcua_NodeClassMask;
extern int hf_opcua_ContinuationPoint;
extern int hf_opcua_ReleaseContinuationPoint;
extern int hf_opcua_RevisedContinuationPoint;
extern int hf_opcua_MaxDescriptionsToReturn;
extern int hf_opcua_MaxReferencesToReturn;
extern int hf_opcua_MaxReferencedNodesToReturn;
extern int hf_opcua_MaxTime;
extern int hf_opcua_MaxAge;
extern int hf_opcua_ReleaseContinuationPoints;
extern int hf_opcua_SubscriptionId;
extern int hf_opcua_MonitoredItemIds;
extern int hf_opcua_TriggeringItemId;
extern int hf_opcua_LinksToAdd;
extern int hf_opcua_LinksToRemove;
extern int hf_opcua_AddResults;
extern int hf_opcua_RemoveResults;
extern int hf_opcua_RequestedPublishingInterval;
extern int hf_opcua_RequestedLifetimeCounter;
extern int hf_opcua_RequestedMaxKeepAliveCount;
extern int hf_opcua_PublishingEnabled;
extern int hf_opcua_Priority;
extern int hf_opcua_RevisedPublishingInterval;
extern int hf_opcua_RevisedLifetimeCounter;
extern int hf_opcua_RevisedMaxKeepAliveCount;
extern int hf_opcua_SubscriptionIds;
extern int hf_opcua_AvailableSequenceNumbers;
extern int hf_opcua_MoreNotifications;
extern int hf_opcua_RetransmitSequenceNumber;
extern int hf_opcua_IsInverse;
extern int hf_opcua_ServerIndex;
extern int hf_opcua_NodeClass;
extern int hf_opcua_EventNotifier;
extern int hf_opcua_IsAbstract;
extern int hf_opcua_ArraySize;
extern int hf_opcua_AccessLevel;
extern int hf_opcua_UserAccessLevel;
extern int hf_opcua_MinimumSamplingInterval;
extern int hf_opcua_Historizing;
extern int hf_opcua_Symmetric;
extern int hf_opcua_Executable;
extern int hf_opcua_UserExecutable;
extern int hf_opcua_ContainsNoLoops;
extern int hf_opcua_Index;
extern int hf_opcua_Uri;
extern int hf_opcua_Name;
extern int hf_opcua_StatusCode;
extern int hf_opcua_EventId;
extern int hf_opcua_SourceName;
extern int hf_opcua_Time;
extern int hf_opcua_ReceiveTime;
extern int hf_opcua_Severity;
extern int hf_opcua_Digest;
extern int hf_opcua_SymmetricSignature;
extern int hf_opcua_SymmetricKeyWrap;
extern int hf_opcua_SymmetricEncryption;
extern int hf_opcua_SymmetricKeyLength;
extern int hf_opcua_AsymmetricSignature;
extern int hf_opcua_AsymmetricKeyWrap;
extern int hf_opcua_AsymmetricEncryption;
extern int hf_opcua_MinimumAsymmetricKeyLength;
extern int hf_opcua_MaximumAsymmetricKeyLength;
extern int hf_opcua_DerivedKey;
extern int hf_opcua_DerivedEncryptionKeyLength;
extern int hf_opcua_DerivedSignatureKeyLength;
extern int hf_opcua_IssuerType;
extern int hf_opcua_IssuerUrl;
extern int hf_opcua_ServerUri;
extern int hf_opcua_DiscoveryUrls;
extern int hf_opcua_EndpointUrl;
extern int hf_opcua_SupportedProfiles;
extern int hf_opcua_SendTimeout;
extern int hf_opcua_OperationTimeout;
extern int hf_opcua_UseBinaryEncoding;
extern int hf_opcua_MaxMessageSize;
extern int hf_opcua_MaxArrayLength;
extern int hf_opcua_MaxStringLength;
extern int hf_opcua_UserName;
extern int hf_opcua_Password;
extern int hf_opcua_HashAlgorithm;
extern int hf_opcua_CertificateData;
extern int hf_opcua_TokenData;
extern int hf_opcua_ProfileUri;
extern int hf_opcua_ProfileName;
extern int hf_opcua_ApplicationUri;
extern int hf_opcua_ManufacturerName;
extern int hf_opcua_ApplicationName;
extern int hf_opcua_SoftwareVersion;
extern int hf_opcua_BuildNumber;
extern int hf_opcua_BuildDate;
extern int hf_opcua_IssuedBy;
extern int hf_opcua_IssuedDate;
extern int hf_opcua_ExpirationDate;
extern int hf_opcua_ApplicationCertificate;
extern int hf_opcua_IssuerCertificateThumbprint;
extern int hf_opcua_IssuerSignatureAlgorithm;
extern int hf_opcua_IssuerSignature;
extern int hf_opcua_IsForward;
extern int hf_opcua_TargetServerUri;
extern int hf_opcua_TargetNodeClass;
extern int hf_opcua_DeleteTargetReferences;
extern int hf_opcua_ServerId;
extern int hf_opcua_ServiceLevel;
extern int hf_opcua_SamplingRate;
extern int hf_opcua_SamplingErrorCount;
extern int hf_opcua_SampledMonitoredItemsCount;
extern int hf_opcua_MaxSampledMonitoredItemsCount;
extern int hf_opcua_DisabledMonitoredItemsSamplingCount;
extern int hf_opcua_ServerViewCount;
extern int hf_opcua_CurrentSessionCount;
extern int hf_opcua_CumulatedSessionCount;
extern int hf_opcua_SecurityRejectedSessionCount;
extern int hf_opcua_RejectSessionCount;
extern int hf_opcua_SessionTimeoutCount;
extern int hf_opcua_SessionAbortCount;
extern int hf_opcua_SamplingRateCount;
extern int hf_opcua_PublishingRateCount;
extern int hf_opcua_CurrentSubscriptionCount;
extern int hf_opcua_CumulatedSubscriptionCount;
extern int hf_opcua_SecurityRejectedRequestsCount;
extern int hf_opcua_RejectedRequestsCount;
extern int hf_opcua_StartTime;
extern int hf_opcua_CurrentTime;
extern int hf_opcua_TotalCount;
extern int hf_opcua_UnauthorizedCount;
extern int hf_opcua_ErrorCount;
extern int hf_opcua_ActualSessionTimeout;
extern int hf_opcua_ClientConnectionTime;
extern int hf_opcua_ClientLastContactTime;
extern int hf_opcua_CurrentSubscriptionsCount;
extern int hf_opcua_CurrentMonitoredItemsCount;
extern int hf_opcua_CurrentPublishRequestsInQueue;
extern int hf_opcua_CurrentPublishTimerExpirations;
extern int hf_opcua_KeepAliveCount;
extern int hf_opcua_CurrentRepublishRequestsInQueue;
extern int hf_opcua_MaxRepublishRequestsInQueue;
extern int hf_opcua_RepublishCounter;
extern int hf_opcua_PublishingCount;
extern int hf_opcua_PublishingQueueOverflowCount;
extern int hf_opcua_ClientUserIdOfSession;
extern int hf_opcua_ClientUserIdHistory;
extern int hf_opcua_AuthenticationMechanism;
extern int hf_opcua_Encoding;
extern int hf_opcua_TransportProtocol;
extern int hf_opcua_SecurityPolicy;
extern int hf_opcua_PublishingInterval;
extern int hf_opcua_MaxKeepAliveCount;
extern int hf_opcua_ModifyCount;
extern int hf_opcua_EnableCount;
extern int hf_opcua_DisableCount;
extern int hf_opcua_RepublishRequestCount;
extern int hf_opcua_RepublishMessageRequestCount;
extern int hf_opcua_RepublishMessageCount;
extern int hf_opcua_TransferRequestCount;
extern int hf_opcua_TransferredToAltClientCount;
extern int hf_opcua_TransferredToSameClientCount;
extern int hf_opcua_PublishRequestCount;
extern int hf_opcua_DataChangeNotificationsCount;
extern int hf_opcua_EventNotificationsCount;
extern int hf_opcua_NotificationsCount;
extern int hf_opcua_LateStateCount;
extern int hf_opcua_KeepAliveStateCount;
extern int hf_opcua_Low;
extern int hf_opcua_High;
extern int hf_opcua_NamespaceUri;
extern int hf_opcua_UnitId;
extern int hf_opcua_Message;
extern int hf_opcua_AnnotationTime;
extern int hf_opcua_Id;
extern int hf_opcua_Description;
extern int hf_opcua_Timestamp;
extern int hf_opcua_Boolean;
extern int hf_opcua_SByte;
extern int hf_opcua_Byte;
extern int hf_opcua_Int16;
extern int hf_opcua_UInt16;
extern int hf_opcua_Int32;
extern int hf_opcua_UInt32;
extern int hf_opcua_Int64;
extern int hf_opcua_UInt64;
extern int hf_opcua_Float;
extern int hf_opcua_Double;
extern int hf_opcua_String;
extern int hf_opcua_DateTime;
extern int hf_opcua_Guid;
extern int hf_opcua_ByteString;
extern int hf_opcua_XmlElement;
extern int hf_opcua_RequestId;
extern int hf_opcua_ReturnDiagnostics;
extern int hf_opcua_AuditLogEntryId;
extern int hf_opcua_TimeoutHint;
extern int hf_opcua_ServiceResult;
extern int hf_opcua_StringTable;
extern int hf_opcua_Value1;
extern int hf_opcua_Value2;
extern int hf_opcua_Booleans;
extern int hf_opcua_SBytes;
extern int hf_opcua_Int16s;
extern int hf_opcua_UInt16s;
extern int hf_opcua_Int32s;
extern int hf_opcua_UInt32s;
extern int hf_opcua_Int64s;
extern int hf_opcua_UInt64s;
extern int hf_opcua_Floats;
extern int hf_opcua_Doubles;
extern int hf_opcua_Strings;
extern int hf_opcua_DateTimes;
extern int hf_opcua_Guids;
extern int hf_opcua_ByteStrings;
extern int hf_opcua_XmlElements;
extern int hf_opcua_StatusCodes;
extern int hf_opcua_SemaphoreFilePath;
extern int hf_opcua_IsOnline;
extern int hf_opcua_ChannelId;
extern int hf_opcua_TokenId;
extern int hf_opcua_CreatedAt;
extern int hf_opcua_RevisedLifetime;
extern int hf_opcua_Algorithm;
extern int hf_opcua_Signature;
extern int hf_opcua_PropertyStatusCode;
extern int hf_opcua_ViewVersion;
extern int hf_opcua_RelativePath;
extern int hf_opcua_AttributeId;
extern int hf_opcua_IndexRange;
extern int hf_opcua_IncludeSubTypes;
extern int hf_opcua_Alias;
extern int hf_opcua_Result;
extern int hf_opcua_IndexOfInvalidElement;
extern int hf_opcua_AttributeStatusCodes;
extern int hf_opcua_NumValuesPerNode;
extern int hf_opcua_EndTime;
extern int hf_opcua_IsReadModified;
extern int hf_opcua_ReturnBounds;
extern int hf_opcua_ResampleInterval;
extern int hf_opcua_ReqTimes;
extern int hf_opcua_ClientHandle;
extern int hf_opcua_PerformInsert;
extern int hf_opcua_PerformReplace;
extern int hf_opcua_IsDeleteModified;
extern int hf_opcua_OperationResult;
extern int hf_opcua_InputArgumentResults;
extern int hf_opcua_DeadbandType;
extern int hf_opcua_DeadbandValue;
extern int hf_opcua_SelectClauseResults;
extern int hf_opcua_SamplingInterval;
extern int hf_opcua_QueueSize;
extern int hf_opcua_DiscardOldest;
extern int hf_opcua_MonitoredItemId;
extern int hf_opcua_RevisedSamplingInterval;
extern int hf_opcua_RevisedQueueSize;
extern int hf_opcua_MonitorItemId;
extern int hf_opcua_PublishTime;
extern int hf_opcua_AvailableSequenceNumbersRanges;
/** Register field types. */
void registerFieldTypes(int proto);

View File

@ -0,0 +1,44 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: Parser type definitions.
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
/* declare service parser function prototype */
typedef void (*fctServiceParser)(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
/* declare enum parser function prototype */
typedef void (*fctEnumParser)(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
/* declare type parser function prototype */
typedef void (*fctComplexTypeParser)(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
/* declare type parser function prototype */
typedef void (*fctSimpleTypeParser)(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
typedef struct _ParserEntry
{
int iRequestId;
fctServiceParser pParser;
} ParserEntry;

View File

@ -0,0 +1,984 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Service Type Parser
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "opcua_serviceparser.h"
#include "opcua_complextypeparser.h"
#include "opcua_enumparser.h"
#include "opcua_simpletypes.h"
#include "opcua_hfindeces.h"
gint ett_opcua_TestStackRequest = -1;
void parseTestStackRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TestStackRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TestStackRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_TestId);
parseInt32(subtree, tvb, pOffset, hf_opcua_Iteration);
parseVariant(subtree, tvb, pOffset, "Input");
}
gint ett_opcua_TestStackResponse = -1;
void parseTestStackResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TestStackResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TestStackResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseVariant(subtree, tvb, pOffset, "Output");
}
gint ett_opcua_TestStackExRequest = -1;
void parseTestStackExRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TestStackExRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TestStackExRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_TestId);
parseInt32(subtree, tvb, pOffset, hf_opcua_Iteration);
parseExtensionObject(subtree, tvb, pOffset, "Input");
}
gint ett_opcua_TestStackExResponse = -1;
void parseTestStackExResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TestStackExResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TestStackExResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseExtensionObject(subtree, tvb, pOffset, "Output");
}
gint ett_opcua_FindServersRequest = -1;
void parseFindServersRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "FindServersRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_FindServersRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "LocaleIds", parseLocalizedText);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_ServerUris, parseString);
}
gint ett_opcua_FindServersResponse = -1;
void parseFindServersResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "FindServersResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_FindServersResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Servers", parseServerDescription);
}
gint ett_opcua_GetEndpointsRequest = -1;
void parseGetEndpointsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "GetEndpointsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_GetEndpointsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "LocaleIds", parseLocalizedText);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_ProfileUris, parseString);
}
gint ett_opcua_GetEndpointsResponse = -1;
void parseGetEndpointsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "GetEndpointsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_GetEndpointsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Endpoints", parseEndpointDescription);
}
gint ett_opcua_RegisterServerRequest = -1;
void parseRegisterServerRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "RegisterServerRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_RegisterServerRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseRegisteredServer(subtree, tvb, pOffset, "Server");
}
gint ett_opcua_RegisterServerResponse = -1;
void parseRegisterServerResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "RegisterServerResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_RegisterServerResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
}
gint ett_opcua_OpenSecureChannelRequest = -1;
void parseOpenSecureChannelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "OpenSecureChannelRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_OpenSecureChannelRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseByteString(subtree, tvb, pOffset, hf_opcua_ClientCertificate);
parseSecurityTokenRequestType(subtree, tvb, pOffset);
parseGuid(subtree, tvb, pOffset, hf_opcua_SecureChannelId);
parseMessageSecurityMode(subtree, tvb, pOffset);
parseString(subtree, tvb, pOffset, hf_opcua_SecurityPolicyUri);
parseSecurityPolicy(subtree, tvb, pOffset, "SecurityPolicy");
parseByteString(subtree, tvb, pOffset, hf_opcua_ClientNonce);
parseInt32(subtree, tvb, pOffset, hf_opcua_RequestedLifetime);
}
gint ett_opcua_OpenSecureChannelResponse = -1;
void parseOpenSecureChannelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "OpenSecureChannelResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_OpenSecureChannelResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseByteString(subtree, tvb, pOffset, hf_opcua_ServerCertificate);
parseChannelSecurityToken(subtree, tvb, pOffset, "SecurityToken");
parseByteString(subtree, tvb, pOffset, hf_opcua_ServerNonce);
}
gint ett_opcua_CloseSecureChannelRequest = -1;
void parseCloseSecureChannelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CloseSecureChannelRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CloseSecureChannelRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseGuid(subtree, tvb, pOffset, hf_opcua_SecureChannelId);
}
gint ett_opcua_CloseSecureChannelResponse = -1;
void parseCloseSecureChannelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CloseSecureChannelResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CloseSecureChannelResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
}
gint ett_opcua_CreateSessionRequest = -1;
void parseCreateSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateSessionRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateSessionRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseString(subtree, tvb, pOffset, hf_opcua_ClientName);
parseByteString(subtree, tvb, pOffset, hf_opcua_ClientNonce);
parseByteString(subtree, tvb, pOffset, hf_opcua_ClientCertificate);
parseInt32(subtree, tvb, pOffset, hf_opcua_RequestedSessionTimeout);
}
gint ett_opcua_CreateSessionResponse = -1;
void parseCreateSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateSessionResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateSessionResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SessionId);
parseInt32(subtree, tvb, pOffset, hf_opcua_RevisedSessionTimeout);
parseByteString(subtree, tvb, pOffset, hf_opcua_ServerNonce);
parseByteString(subtree, tvb, pOffset, hf_opcua_ServerCertificate);
parseArrayComplex(subtree, tvb, pOffset, "ServerSoftwareCertificates", parseSignedSoftwareCertificate);
parseSignatureData(subtree, tvb, pOffset, "ServerSignature");
}
gint ett_opcua_ActivateSessionRequest = -1;
void parseActivateSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ActivateSessionRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ActivateSessionRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseSignatureData(subtree, tvb, pOffset, "ClientSignature");
parseArrayComplex(subtree, tvb, pOffset, "ClientSoftwareCertificates", parseSignedSoftwareCertificate);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_LocaleIds, parseString);
parseExtensionObject(subtree, tvb, pOffset, "UserIdentityToken");
parseSignatureData(subtree, tvb, pOffset, "UserTokenSignature");
}
gint ett_opcua_ActivateSessionResponse = -1;
void parseActivateSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ActivateSessionResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ActivateSessionResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseByteString(subtree, tvb, pOffset, hf_opcua_ServerNonce);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_CertificateResults, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "CertificateDiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_CloseSessionRequest = -1;
void parseCloseSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CloseSessionRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CloseSessionRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
}
gint ett_opcua_CloseSessionResponse = -1;
void parseCloseSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CloseSessionResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CloseSessionResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
}
gint ett_opcua_CancelRequest = -1;
void parseCancelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CancelRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CancelRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SequenceNumber);
}
gint ett_opcua_CancelResponse = -1;
void parseCancelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CancelResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CancelResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
}
gint ett_opcua_AddNodesRequest = -1;
void parseAddNodesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "AddNodesRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_AddNodesRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "NodesToAdd", parseAddNodesItem);
}
gint ett_opcua_AddNodesResponse = -1;
void parseAddNodesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "AddNodesResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_AddNodesResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseAddNodesResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_AddReferencesRequest = -1;
void parseAddReferencesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "AddReferencesRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_AddReferencesRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "ReferencesToAdd", parseAddReferencesItem);
}
gint ett_opcua_AddReferencesResponse = -1;
void parseAddReferencesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "AddReferencesResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_AddReferencesResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_DeleteNodesRequest = -1;
void parseDeleteNodesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteNodesRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteNodesRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "NodesToDelete", parseDeleteNodesItem);
}
gint ett_opcua_DeleteNodesResponse = -1;
void parseDeleteNodesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteNodesResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteNodesResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "Diagnostics", parseDiagnosticInfo);
}
gint ett_opcua_DeleteReferencesRequest = -1;
void parseDeleteReferencesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteReferencesRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteReferencesRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "ReferencesToDelete", parseDeleteReferencesItem);
}
gint ett_opcua_DeleteReferencesResponse = -1;
void parseDeleteReferencesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteReferencesResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteReferencesResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_BrowsePropertiesRequest = -1;
void parseBrowsePropertiesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowsePropertiesRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowsePropertiesRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "NodesToAccess", parseNodeId);
parseArrayComplex(subtree, tvb, pOffset, "Properties", parseQualifiedName);
}
gint ett_opcua_BrowsePropertiesResponse = -1;
void parseBrowsePropertiesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowsePropertiesResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowsePropertiesResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "NodeResults", parseBrowsePropertiesResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_BrowseRequest = -1;
void parseBrowseRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowseRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowseRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseViewDescription(subtree, tvb, pOffset, "View");
parseNodeId(subtree, tvb, pOffset, "NodeToBrowse");
parseUInt32(subtree, tvb, pOffset, hf_opcua_MaxResultsToReturn);
parseBrowseDirection(subtree, tvb, pOffset);
parseNodeId(subtree, tvb, pOffset, "ReferenceTypeId");
parseBoolean(subtree, tvb, pOffset, hf_opcua_IncludeSubtypes);
parseInt32(subtree, tvb, pOffset, hf_opcua_NodeClassMask);
}
gint ett_opcua_BrowseResponse = -1;
void parseBrowseResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowseResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowseResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseByteString(subtree, tvb, pOffset, hf_opcua_ContinuationPoint);
parseArrayComplex(subtree, tvb, pOffset, "References", parseReferenceDescription);
}
gint ett_opcua_BrowseNextRequest = -1;
void parseBrowseNextRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowseNextRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowseNextRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseBoolean(subtree, tvb, pOffset, hf_opcua_ReleaseContinuationPoint);
parseByteString(subtree, tvb, pOffset, hf_opcua_ContinuationPoint);
}
gint ett_opcua_BrowseNextResponse = -1;
void parseBrowseNextResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "BrowseNextResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_BrowseNextResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseByteString(subtree, tvb, pOffset, hf_opcua_RevisedContinuationPoint);
parseArrayComplex(subtree, tvb, pOffset, "References", parseReferenceDescription);
}
gint ett_opcua_TranslateBrowsePathsToNodeIdsRequest = -1;
void parseTranslateBrowsePathsToNodeIdsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TranslateBrowsePathsToNodeIdsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TranslateBrowsePathsToNodeIdsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "BrowsePaths", parseBrowsePath);
}
gint ett_opcua_TranslateBrowsePathsToNodeIdsResponse = -1;
void parseTranslateBrowsePathsToNodeIdsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TranslateBrowsePathsToNodeIdsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TranslateBrowsePathsToNodeIdsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseTranslateBrowsePathResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_QueryFirstRequest = -1;
void parseQueryFirstRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "QueryFirstRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_QueryFirstRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseViewDescription(subtree, tvb, pOffset, "View");
parseArrayComplex(subtree, tvb, pOffset, "NodeTypes", parseNodeTypeDescription);
parseContentFilter(subtree, tvb, pOffset, "Filter");
parseUInt32(subtree, tvb, pOffset, hf_opcua_MaxDescriptionsToReturn);
parseUInt32(subtree, tvb, pOffset, hf_opcua_MaxReferencesToReturn);
parseUInt32(subtree, tvb, pOffset, hf_opcua_MaxReferencedNodesToReturn);
parseUInt32(subtree, tvb, pOffset, hf_opcua_MaxTime);
}
gint ett_opcua_QueryFirstResponse = -1;
void parseQueryFirstResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "QueryFirstResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_QueryFirstResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "QueryDataSets", parseQueryDataSet);
parseByteString(subtree, tvb, pOffset, hf_opcua_ContinuationPoint);
parseArrayComplex(subtree, tvb, pOffset, "Results", parseQueryResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfo", parseDiagnosticInfo);
parseContentFilterResult(subtree, tvb, pOffset, "ContentFilterResult");
}
gint ett_opcua_QueryNextRequest = -1;
void parseQueryNextRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "QueryNextRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_QueryNextRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseBoolean(subtree, tvb, pOffset, hf_opcua_ReleaseContinuationPoint);
parseByteString(subtree, tvb, pOffset, hf_opcua_ContinuationPoint);
}
gint ett_opcua_QueryNextResponse = -1;
void parseQueryNextResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "QueryNextResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_QueryNextResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "QueryDataSets", parseQueryDataSet);
parseByteString(subtree, tvb, pOffset, hf_opcua_RevisedContinuationPoint);
}
gint ett_opcua_ReadRequest = -1;
void parseReadRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ReadRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ReadRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseInt32(subtree, tvb, pOffset, hf_opcua_MaxAge);
parseTimestampsToReturn(subtree, tvb, pOffset);
parseArrayComplex(subtree, tvb, pOffset, "NodesToRead", parseReadValueId);
}
gint ett_opcua_ReadResponse = -1;
void parseReadResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ReadResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ReadResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseDataValue);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_HistoryReadRequest = -1;
void parseHistoryReadRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "HistoryReadRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_HistoryReadRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseExtensionObject(subtree, tvb, pOffset, "HistoryReadDetails");
parseTimestampsToReturn(subtree, tvb, pOffset);
parseBoolean(subtree, tvb, pOffset, hf_opcua_ReleaseContinuationPoints);
parseArrayComplex(subtree, tvb, pOffset, "NodesToRead", parseHistoryReadValueId);
}
gint ett_opcua_HistoryReadResponse = -1;
void parseHistoryReadResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "HistoryReadResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_HistoryReadResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseHistoryReadResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_WriteRequest = -1;
void parseWriteRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "WriteRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_WriteRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "NodesToWrite", parseWriteValue);
}
gint ett_opcua_WriteResponse = -1;
void parseWriteResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "WriteResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_WriteResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_HistoryUpdateRequest = -1;
void parseHistoryUpdateRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "HistoryUpdateRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_HistoryUpdateRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "HistoryUpdateDetails", parseExtensionObject);
}
gint ett_opcua_HistoryUpdateResponse = -1;
void parseHistoryUpdateResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "HistoryUpdateResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_HistoryUpdateResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseHistoryUpdateResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_CallRequest = -1;
void parseCallRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CallRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CallRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "MethodsToCall", parseCallRequestItem);
}
gint ett_opcua_CallResponse = -1;
void parseCallResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CallResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CallResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseCallResultItem);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_CreateMonitoredItemsRequest = -1;
void parseCreateMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateMonitoredItemsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateMonitoredItemsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseTimestampsToReturn(subtree, tvb, pOffset);
parseArrayComplex(subtree, tvb, pOffset, "ItemsToCreate", parseMonitoredItemCreateRequest);
}
gint ett_opcua_CreateMonitoredItemsResponse = -1;
void parseCreateMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateMonitoredItemsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateMonitoredItemsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseMonitoredItemCreateResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_ModifyMonitoredItemsRequest = -1;
void parseModifyMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ModifyMonitoredItemsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ModifyMonitoredItemsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseTimestampsToReturn(subtree, tvb, pOffset);
parseArrayComplex(subtree, tvb, pOffset, "ItemsToModify", parseMonitoredItemModifyRequest);
}
gint ett_opcua_ModifyMonitoredItemsResponse = -1;
void parseModifyMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ModifyMonitoredItemsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ModifyMonitoredItemsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseMonitoredItemModifyResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_SetMonitoringModeRequest = -1;
void parseSetMonitoringModeRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetMonitoringModeRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetMonitoringModeRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseMonitoringMode(subtree, tvb, pOffset);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_MonitoredItemIds, parseUInt32);
}
gint ett_opcua_SetMonitoringModeResponse = -1;
void parseSetMonitoringModeResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetMonitoringModeResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetMonitoringModeResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_SetTriggeringRequest = -1;
void parseSetTriggeringRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetTriggeringRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetTriggeringRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseUInt32(subtree, tvb, pOffset, hf_opcua_TriggeringItemId);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_LinksToAdd, parseUInt32);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_LinksToRemove, parseUInt32);
}
gint ett_opcua_SetTriggeringResponse = -1;
void parseSetTriggeringResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetTriggeringResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetTriggeringResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_AddResults, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "AddDiagnosticInfos", parseDiagnosticInfo);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_RemoveResults, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "RemoveDiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_DeleteMonitoredItemsRequest = -1;
void parseDeleteMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteMonitoredItemsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteMonitoredItemsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_MonitoredItemIds, parseUInt32);
}
gint ett_opcua_DeleteMonitoredItemsResponse = -1;
void parseDeleteMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteMonitoredItemsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteMonitoredItemsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_CreateSubscriptionRequest = -1;
void parseCreateSubscriptionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateSubscriptionRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateSubscriptionRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseInt32(subtree, tvb, pOffset, hf_opcua_RequestedPublishingInterval);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RequestedLifetimeCounter);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RequestedMaxKeepAliveCount);
parseBoolean(subtree, tvb, pOffset, hf_opcua_PublishingEnabled);
parseByte(subtree, tvb, pOffset, hf_opcua_Priority);
}
gint ett_opcua_CreateSubscriptionResponse = -1;
void parseCreateSubscriptionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "CreateSubscriptionResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_CreateSubscriptionResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseInt32(subtree, tvb, pOffset, hf_opcua_RevisedPublishingInterval);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RevisedLifetimeCounter);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RevisedMaxKeepAliveCount);
}
gint ett_opcua_ModifySubscriptionRequest = -1;
void parseModifySubscriptionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ModifySubscriptionRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ModifySubscriptionRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseInt32(subtree, tvb, pOffset, hf_opcua_RequestedPublishingInterval);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RequestedLifetimeCounter);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RequestedMaxKeepAliveCount);
parseByte(subtree, tvb, pOffset, hf_opcua_Priority);
}
gint ett_opcua_ModifySubscriptionResponse = -1;
void parseModifySubscriptionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "ModifySubscriptionResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_ModifySubscriptionResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseInt32(subtree, tvb, pOffset, hf_opcua_RevisedPublishingInterval);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RevisedLifetimeCounter);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RevisedMaxKeepAliveCount);
}
gint ett_opcua_SetPublishingModeRequest = -1;
void parseSetPublishingModeRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetPublishingModeRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetPublishingModeRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseBoolean(subtree, tvb, pOffset, hf_opcua_PublishingEnabled);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_SubscriptionIds, parseUInt32);
}
gint ett_opcua_SetPublishingModeResponse = -1;
void parseSetPublishingModeResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "SetPublishingModeResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_SetPublishingModeResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_PublishRequest = -1;
void parsePublishRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "PublishRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_PublishRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArrayComplex(subtree, tvb, pOffset, "SubscriptionAcknowledgements", parseSubscriptionAcknowledgement);
}
gint ett_opcua_PublishResponse = -1;
void parsePublishResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "PublishResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_PublishResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseArraySimple(subtree, tvb, pOffset, hf_opcua_AvailableSequenceNumbers, parseUInt32);
parseBoolean(subtree, tvb, pOffset, hf_opcua_MoreNotifications);
parseNotificationMessage(subtree, tvb, pOffset, "NotificationMessage");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_RepublishRequest = -1;
void parseRepublishRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "RepublishRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_RepublishRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseUInt32(subtree, tvb, pOffset, hf_opcua_SubscriptionId);
parseUInt32(subtree, tvb, pOffset, hf_opcua_RetransmitSequenceNumber);
}
gint ett_opcua_RepublishResponse = -1;
void parseRepublishResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "RepublishResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_RepublishResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseNotificationMessage(subtree, tvb, pOffset, "NotificationMessage");
}
gint ett_opcua_TransferSubscriptionsRequest = -1;
void parseTransferSubscriptionsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TransferSubscriptionsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TransferSubscriptionsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_SubscriptionIds, parseUInt32);
}
gint ett_opcua_TransferSubscriptionsResponse = -1;
void parseTransferSubscriptionsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "TransferSubscriptionsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_TransferSubscriptionsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArrayComplex(subtree, tvb, pOffset, "Results", parseTransferResult);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
gint ett_opcua_DeleteSubscriptionsRequest = -1;
void parseDeleteSubscriptionsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteSubscriptionsRequest");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteSubscriptionsRequest);
parseRequestHeader(subtree, tvb, pOffset, "RequestHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_SubscriptionIds, parseUInt32);
}
gint ett_opcua_DeleteSubscriptionsResponse = -1;
void parseDeleteSubscriptionsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "DeleteSubscriptionsResponse");
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_DeleteSubscriptionsResponse);
parseResponseHeader(subtree, tvb, pOffset, "ResponseHeader");
parseArraySimple(subtree, tvb, pOffset, hf_opcua_Results, parseStatusCode);
parseArrayComplex(subtree, tvb, pOffset, "DiagnosticInfos", parseDiagnosticInfo);
}
/** Setup protocol subtree array */
static gint *ett[] =
{
&ett_opcua_TestStackRequest,
&ett_opcua_TestStackResponse,
&ett_opcua_TestStackExRequest,
&ett_opcua_TestStackExResponse,
&ett_opcua_FindServersRequest,
&ett_opcua_FindServersResponse,
&ett_opcua_GetEndpointsRequest,
&ett_opcua_GetEndpointsResponse,
&ett_opcua_RegisterServerRequest,
&ett_opcua_RegisterServerResponse,
&ett_opcua_OpenSecureChannelRequest,
&ett_opcua_OpenSecureChannelResponse,
&ett_opcua_CloseSecureChannelRequest,
&ett_opcua_CloseSecureChannelResponse,
&ett_opcua_CreateSessionRequest,
&ett_opcua_CreateSessionResponse,
&ett_opcua_ActivateSessionRequest,
&ett_opcua_ActivateSessionResponse,
&ett_opcua_CloseSessionRequest,
&ett_opcua_CloseSessionResponse,
&ett_opcua_CancelRequest,
&ett_opcua_CancelResponse,
&ett_opcua_AddNodesRequest,
&ett_opcua_AddNodesResponse,
&ett_opcua_AddReferencesRequest,
&ett_opcua_AddReferencesResponse,
&ett_opcua_DeleteNodesRequest,
&ett_opcua_DeleteNodesResponse,
&ett_opcua_DeleteReferencesRequest,
&ett_opcua_DeleteReferencesResponse,
&ett_opcua_BrowsePropertiesRequest,
&ett_opcua_BrowsePropertiesResponse,
&ett_opcua_BrowseRequest,
&ett_opcua_BrowseResponse,
&ett_opcua_BrowseNextRequest,
&ett_opcua_BrowseNextResponse,
&ett_opcua_TranslateBrowsePathsToNodeIdsRequest,
&ett_opcua_TranslateBrowsePathsToNodeIdsResponse,
&ett_opcua_QueryFirstRequest,
&ett_opcua_QueryFirstResponse,
&ett_opcua_QueryNextRequest,
&ett_opcua_QueryNextResponse,
&ett_opcua_ReadRequest,
&ett_opcua_ReadResponse,
&ett_opcua_HistoryReadRequest,
&ett_opcua_HistoryReadResponse,
&ett_opcua_WriteRequest,
&ett_opcua_WriteResponse,
&ett_opcua_HistoryUpdateRequest,
&ett_opcua_HistoryUpdateResponse,
&ett_opcua_CallRequest,
&ett_opcua_CallResponse,
&ett_opcua_CreateMonitoredItemsRequest,
&ett_opcua_CreateMonitoredItemsResponse,
&ett_opcua_ModifyMonitoredItemsRequest,
&ett_opcua_ModifyMonitoredItemsResponse,
&ett_opcua_SetMonitoringModeRequest,
&ett_opcua_SetMonitoringModeResponse,
&ett_opcua_SetTriggeringRequest,
&ett_opcua_SetTriggeringResponse,
&ett_opcua_DeleteMonitoredItemsRequest,
&ett_opcua_DeleteMonitoredItemsResponse,
&ett_opcua_CreateSubscriptionRequest,
&ett_opcua_CreateSubscriptionResponse,
&ett_opcua_ModifySubscriptionRequest,
&ett_opcua_ModifySubscriptionResponse,
&ett_opcua_SetPublishingModeRequest,
&ett_opcua_SetPublishingModeResponse,
&ett_opcua_PublishRequest,
&ett_opcua_PublishResponse,
&ett_opcua_RepublishRequest,
&ett_opcua_RepublishResponse,
&ett_opcua_TransferSubscriptionsRequest,
&ett_opcua_TransferSubscriptionsResponse,
&ett_opcua_DeleteSubscriptionsRequest,
&ett_opcua_DeleteSubscriptionsResponse,
};
void registerServiceTypes()
{
proto_register_subtree_array(ett, array_length(ett));
}

View File

@ -0,0 +1,107 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Service Type Parser
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
void parseTestStackRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTestStackResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTestStackExRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTestStackExResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseFindServersRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseFindServersResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseGetEndpointsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseGetEndpointsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseRegisterServerRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseRegisterServerResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseOpenSecureChannelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseOpenSecureChannelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCloseSecureChannelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCloseSecureChannelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseActivateSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseActivateSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCloseSessionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCloseSessionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCancelRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCancelResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAddNodesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAddNodesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAddReferencesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAddReferencesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteNodesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteNodesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteReferencesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteReferencesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowsePropertiesRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowsePropertiesResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowseRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowseResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowseNextRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseBrowseNextResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTranslateBrowsePathsToNodeIdsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTranslateBrowsePathsToNodeIdsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseQueryFirstRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseQueryFirstResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseQueryNextRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseQueryNextResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseReadRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseReadResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseHistoryReadRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseHistoryReadResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseWriteRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseWriteResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseHistoryUpdateRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseHistoryUpdateResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCallRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCallResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseModifyMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseModifyMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetMonitoringModeRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetMonitoringModeResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetTriggeringRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetTriggeringResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteMonitoredItemsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteMonitoredItemsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateSubscriptionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseCreateSubscriptionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseModifySubscriptionRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseModifySubscriptionResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetPublishingModeRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseSetPublishingModeResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parsePublishRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parsePublishResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseRepublishRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseRepublishResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTransferSubscriptionsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseTransferSubscriptionsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteSubscriptionsRequest(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDeleteSubscriptionsResponse(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void registerServiceTypes();

View File

@ -0,0 +1,209 @@
/******************************************************************************
** $Id$
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: Service table and service dispatcher.
**
** This file was autogenerated on 8.5.2007 18:53:26.
** DON'T MODIFY THIS FILE!
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "opcua_identifiers.h"
#include "opcua_serviceparser.h"
ParserEntry g_arParserTable[] = {
{ 1358, parseTestStackRequest },
{ 1363, parseTestStackResponse },
{ 1368, parseTestStackExRequest },
{ 1373, parseTestStackExResponse },
{ 1414, parseFindServersRequest },
{ 1419, parseFindServersResponse },
{ 1424, parseGetEndpointsRequest },
{ 1429, parseGetEndpointsResponse },
{ 1439, parseRegisterServerRequest },
{ 1444, parseRegisterServerResponse },
{ 1454, parseOpenSecureChannelRequest },
{ 1459, parseOpenSecureChannelResponse },
{ 1464, parseCloseSecureChannelRequest },
{ 1469, parseCloseSecureChannelResponse },
{ 1479, parseCreateSessionRequest },
{ 1484, parseCreateSessionResponse },
{ 1489, parseActivateSessionRequest },
{ 1494, parseActivateSessionResponse },
{ 1499, parseCloseSessionRequest },
{ 1504, parseCloseSessionResponse },
{ 1509, parseCancelRequest },
{ 1514, parseCancelResponse },
{ 1524, parseAddNodesRequest },
{ 1529, parseAddNodesResponse },
{ 1534, parseAddReferencesRequest },
{ 1539, parseAddReferencesResponse },
{ 1544, parseDeleteNodesRequest },
{ 1549, parseDeleteNodesResponse },
{ 1554, parseDeleteReferencesRequest },
{ 1559, parseDeleteReferencesResponse },
{ 1574, parseBrowsePropertiesRequest },
{ 1579, parseBrowsePropertiesResponse },
{ 1599, parseBrowseRequest },
{ 1604, parseBrowseResponse },
{ 1609, parseBrowseNextRequest },
{ 1614, parseBrowseNextResponse },
{ 1630, parseTranslateBrowsePathsToNodeIdsRequest },
{ 1635, parseTranslateBrowsePathsToNodeIdsResponse },
{ 1710, parseQueryFirstRequest },
{ 1715, parseQueryFirstResponse },
{ 1720, parseQueryNextRequest },
{ 1725, parseQueryNextResponse },
{ 1740, parseReadRequest },
{ 1745, parseReadResponse },
{ 1790, parseHistoryReadRequest },
{ 1795, parseHistoryReadResponse },
{ 1805, parseWriteRequest },
{ 1810, parseWriteResponse },
{ 1845, parseHistoryUpdateRequest },
{ 1850, parseHistoryUpdateResponse },
{ 1865, parseCallRequest },
{ 1870, parseCallResponse },
{ 1930, parseCreateMonitoredItemsRequest },
{ 1935, parseCreateMonitoredItemsResponse },
{ 1950, parseModifyMonitoredItemsRequest },
{ 1955, parseModifyMonitoredItemsResponse },
{ 1960, parseSetMonitoringModeRequest },
{ 1965, parseSetMonitoringModeResponse },
{ 1970, parseSetTriggeringRequest },
{ 1975, parseSetTriggeringResponse },
{ 1980, parseDeleteMonitoredItemsRequest },
{ 1985, parseDeleteMonitoredItemsResponse },
{ 1990, parseCreateSubscriptionRequest },
{ 1995, parseCreateSubscriptionResponse },
{ 2000, parseModifySubscriptionRequest },
{ 2005, parseModifySubscriptionResponse },
{ 2010, parseSetPublishingModeRequest },
{ 2015, parseSetPublishingModeResponse },
{ 2050, parsePublishRequest },
{ 2055, parsePublishResponse },
{ 2060, parseRepublishRequest },
{ 2065, parseRepublishResponse },
{ 2075, parseTransferSubscriptionsRequest },
{ 2080, parseTransferSubscriptionsResponse },
{ 2085, parseDeleteSubscriptionsRequest },
{ 2090, parseDeleteSubscriptionsResponse }
};
const int g_NumServices = sizeof(g_arParserTable) / sizeof(ParserEntry);
/** Service type table */
const value_string g_requesttypes[] = {
{ 1358, "TestStackRequest" },
{ 1363, "TestStackResponse" },
{ 1368, "TestStackExRequest" },
{ 1373, "TestStackExResponse" },
{ 1414, "FindServersRequest" },
{ 1419, "FindServersResponse" },
{ 1424, "GetEndpointsRequest" },
{ 1429, "GetEndpointsResponse" },
{ 1439, "RegisterServerRequest" },
{ 1444, "RegisterServerResponse" },
{ 1454, "OpenSecureChannelRequest" },
{ 1459, "OpenSecureChannelResponse" },
{ 1464, "CloseSecureChannelRequest" },
{ 1469, "CloseSecureChannelResponse" },
{ 1479, "CreateSessionRequest" },
{ 1484, "CreateSessionResponse" },
{ 1489, "ActivateSessionRequest" },
{ 1494, "ActivateSessionResponse" },
{ 1499, "CloseSessionRequest" },
{ 1504, "CloseSessionResponse" },
{ 1509, "CancelRequest" },
{ 1514, "CancelResponse" },
{ 1524, "AddNodesRequest" },
{ 1529, "AddNodesResponse" },
{ 1534, "AddReferencesRequest" },
{ 1539, "AddReferencesResponse" },
{ 1544, "DeleteNodesRequest" },
{ 1549, "DeleteNodesResponse" },
{ 1554, "DeleteReferencesRequest" },
{ 1559, "DeleteReferencesResponse" },
{ 1574, "BrowsePropertiesRequest" },
{ 1579, "BrowsePropertiesResponse" },
{ 1599, "BrowseRequest" },
{ 1604, "BrowseResponse" },
{ 1609, "BrowseNextRequest" },
{ 1614, "BrowseNextResponse" },
{ 1630, "TranslateBrowsePathsToNodeIdsRequest" },
{ 1635, "TranslateBrowsePathsToNodeIdsResponse" },
{ 1710, "QueryFirstRequest" },
{ 1715, "QueryFirstResponse" },
{ 1720, "QueryNextRequest" },
{ 1725, "QueryNextResponse" },
{ 1740, "ReadRequest" },
{ 1745, "ReadResponse" },
{ 1790, "HistoryReadRequest" },
{ 1795, "HistoryReadResponse" },
{ 1805, "WriteRequest" },
{ 1810, "WriteResponse" },
{ 1845, "HistoryUpdateRequest" },
{ 1850, "HistoryUpdateResponse" },
{ 1865, "CallRequest" },
{ 1870, "CallResponse" },
{ 1930, "CreateMonitoredItemsRequest" },
{ 1935, "CreateMonitoredItemsResponse" },
{ 1950, "ModifyMonitoredItemsRequest" },
{ 1955, "ModifyMonitoredItemsResponse" },
{ 1960, "SetMonitoringModeRequest" },
{ 1965, "SetMonitoringModeResponse" },
{ 1970, "SetTriggeringRequest" },
{ 1975, "SetTriggeringResponse" },
{ 1980, "DeleteMonitoredItemsRequest" },
{ 1985, "DeleteMonitoredItemsResponse" },
{ 1990, "CreateSubscriptionRequest" },
{ 1995, "CreateSubscriptionResponse" },
{ 2000, "ModifySubscriptionRequest" },
{ 2005, "ModifySubscriptionResponse" },
{ 2010, "SetPublishingModeRequest" },
{ 2015, "SetPublishingModeResponse" },
{ 2050, "PublishRequest" },
{ 2055, "PublishResponse" },
{ 2060, "RepublishRequest" },
{ 2065, "RepublishResponse" },
{ 2075, "TransferSubscriptionsRequest" },
{ 2080, "TransferSubscriptionsResponse" },
{ 2085, "DeleteSubscriptionsRequest" },
{ 2090, "DeleteSubscriptionsResponse" },
{ 0, NULL }
};
/** Dispatch all services to a special parser function. */
void dispatchService(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int ServiceId)
{
int index = 0;
while (index < g_NumServices)
{
if (g_arParserTable[index].iRequestId == ServiceId)
{
(*g_arParserTable[index].pParser)(tree, tvb, pOffset);
break;
}
index++;
}
}

View File

@ -0,0 +1,840 @@
/******************************************************************************
** $Id: opcua_simpletypes.c,v 1.1 2007/02/08 11:26:55 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: Implementation of OpcUa built-in type parsers.
** This contains all the simple types and some complex types.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include <epan/dissectors/packet-windows-common.h>
#include "opcua_simpletypes.h"
#include "opcua_hfindeces.h"
#include <string.h>
#include <epan/emem.h>
/* string buffer */
#define MAX_BUFFER 256
#define DIAGNOSTICINFO_ENCODINGMASK_SYMBOLICID_FLAG 0x01
#define DIAGNOSTICINFO_ENCODINGMASK_NAMESPACE_FLAG 0x02
#define DIAGNOSTICINFO_ENCODINGMASK_LOCALIZEDTEXT_FLAG 0x04
#define DIAGNOSTICINFO_ENCODINGMASK_ADDITIONALINFO_FLAG 0x08
#define DIAGNOSTICINFO_ENCODINGMASK_INNERSTATUSCODE_FLAG 0x10
#define DIAGNOSTICINFO_ENCODINGMASK_INNERDIAGNOSTICINFO_FLAG 0x20
#define LOCALIZEDTEXT_ENCODINGBYTE_LOCALE 0x01
#define LOCALIZEDTEXT_ENCODINGBYTE_TEXT 0x02
#define NODEID_URIMASK 0x80
#define DATAVALUE_ENCODINGBYTE_VALUE 0x01
#define DATAVALUE_ENCODINGBYTE_STATUSCODE 0x02
#define DATAVALUE_ENCODINGBYTE_SOURCETIMESTAMP 0x04
#define DATAVALUE_ENCODINGBYTE_SERVERTIMESTAMP 0x08
#define EXTOBJ_ENCODINGMASK_BINBODY_FLAG 0x01
#define EXTOBJ_ENCODINGMASK_XMLBODY_FLAG 0x02
static int hf_opcua_diag_mask_symbolicflag = -1;
static int hf_opcua_diag_mask_namespaceflag = -1;
static int hf_opcua_diag_mask_localizedtextflag = -1;
static int hf_opcua_diag_mask_additionalinfoflag = -1;
static int hf_opcua_diag_mask_innerstatuscodeflag = -1;
static int hf_opcua_diag_mask_innerdiaginfoflag = -1;
static int hf_opcua_loctext_mask_localeflag = -1;
static int hf_opcua_loctext_mask_textflag = -1;
static int hf_opcua_datavalue_mask_valueflag = -1;
static int hf_opcua_datavalue_mask_statuscodeflag = -1;
static int hf_opcua_datavalue_mask_sourcetimestampflag = -1;
static int hf_opcua_datavalue_mask_servertimestampflag = -1;
static int hf_opcua_nodeid_encodingmask = -1;
static int hf_opcua_variant_encodingmask = -1;
static int hf_opcua_nodeid_nsid = -1;
static int hf_opcua_nodeid_numeric = -1;
static int hf_opcua_Locale = -1;
static int hf_opcua_Text = -1;
static int hf_opcua_SourceTimestamp = -1;
static int hf_opcua_ServerTimestamp = -1;
static int hf_opcua_diag_symbolicid = -1;
static int hf_opcua_diag_namespace = -1;
static int hf_opcua_diag_localizedtext = -1;
static int hf_opcua_diag_additionalinfo = -1;
static int hf_opcua_diag_innerstatuscode = -1;
static int hf_opcua_extobj_mask_binbodyflag = -1;
static int hf_opcua_extobj_mask_xmlbodyflag = -1;
/** NodeId encoding mask table */
static const value_string g_nodeidmasks[] = {
{ 0, "Two byte encoded Numeric" },
{ 1, "Four byte encoded Numeric" },
{ 2, "Numeric of arbitrary length" },
{ 3, "String" },
{ 4, "URI" },
{ 5, "GUID" },
{ 6, "ByteString" },
{ 0x80, "UriMask" },
{ 0, NULL }
};
/** UA Variant Type enum */
typedef enum _OpcUa_BuiltInType
{
OpcUaType_Null = 0,
OpcUaType_Boolean = 1,
OpcUaType_SByte = 2,
OpcUaType_Byte = 3,
OpcUaType_Int16 = 4,
OpcUaType_UInt16 = 5,
OpcUaType_Int32 = 6,
OpcUaType_UInt32 = 7,
OpcUaType_Int64 = 8,
OpcUaType_UInt64 = 9,
OpcUaType_Float = 10,
OpcUaType_Double = 11,
OpcUaType_String = 12,
OpcUaType_DateTime = 13,
OpcUaType_Guid = 14,
OpcUaType_ByteString = 15,
OpcUaType_XmlElement = 16,
OpcUaType_NodeId = 17,
OpcUaType_ExpandedNodeId = 18,
OpcUaType_StatusCode = 19,
OpcUaType_DiagnosticInfo = 20,
OpcUaType_QualifiedName = 21,
OpcUaType_LocalizedText = 22,
OpcUaType_ExtensionObject = 23,
OpcUaType_DataValue = 24,
OpcUaType_Variant = 25
}
OpcUa_BuiltInType;
/** Variant encoding mask table */
static const value_string g_VariantTypes[] = {
{ 0, "Null" },
{ 1, "Boolean" },
{ 2, "SByte" },
{ 3, "Byte" },
{ 4, "Int16" },
{ 5, "UInt16" },
{ 6, "Int32" },
{ 7, "UInt32" },
{ 8, "Int64" },
{ 9, "UInt64" },
{ 10, "Float" },
{ 11, "Double" },
{ 12, "String" },
{ 13, "DateTime" },
{ 14, "Guid" },
{ 15, "ByteString" },
{ 16, "XmlElement" },
{ 17, "NodeId" },
{ 18, "ExpandedNodeId" },
{ 19, "StatusCode" },
{ 20, "DiagnosticInfo" },
{ 21, "QualifiedName" },
{ 22, "LocalizedText" },
{ 23, "ExtensionObject" },
{ 24, "DataValue" },
{ 25, "Variant" },
{ 0x80, "Array of Null" },
{ 0x80+1, "Array of Boolean" },
{ 0x80+2, "Array of SByte" },
{ 0x80+3, "Array of Byte" },
{ 0x80+4, "Array of Int16" },
{ 0x80+5, "Array of UInt16" },
{ 0x80+6, "Array of Int32" },
{ 0x80+7, "Array of UInt32" },
{ 0x80+8, "Array of Int64" },
{ 0x80+9, "Array of UInt64" },
{ 0x80+10, "Array of Float" },
{ 0x80+11, "Array of Double" },
{ 0x80+12, "Array of String" },
{ 0x80+13, "Array of DateTime" },
{ 0x80+14, "Array of Guid" },
{ 0x80+15, "Array of ByteString" },
{ 0x80+16, "Array of XmlElement" },
{ 0x80+17, "Array of NodeId" },
{ 0x80+18, "Array of ExpandedNodeId" },
{ 0x80+19, "Array of StatusCode" },
{ 0x80+20, "Array of DiagnosticInfo" },
{ 0x80+21, "Array of QualifiedName" },
{ 0x80+22, "Array of LocalizedText" },
{ 0x80+23, "Array of ExtensionObject" },
{ 0x80+24, "Array of DataValue" },
{ 0x80+25, "Array of Variant" },
{ 0, NULL }
};
#define VARIANT_ARRAYMASK 0x80
/* trees */
static gint ett_opcua_array = -1;
static gint ett_opcua_diagnosticinfo = -1;
static gint ett_opcua_nodeid = -1;
static gint ett_opcua_localeid = -1;
static gint ett_opcua_localizedtext = -1;
static gint ett_opcua_qualifiedname = -1;
static gint ett_opcua_datavalue = -1;
static gint ett_opcua_variant = -1;
static gint ett_opcua_extensionobject = -1;
static gint ett_opcua_extobj_encodingmask = -1;
static gint *ett[] =
{
&ett_opcua_array,
&ett_opcua_diagnosticinfo,
&ett_opcua_nodeid,
&ett_opcua_localeid,
&ett_opcua_localizedtext,
&ett_opcua_qualifiedname,
&ett_opcua_datavalue,
&ett_opcua_variant,
&ett_opcua_extensionobject,
&ett_opcua_extobj_encodingmask
};
static hf_register_info hf[] =
{
/* full name , abbreviation , type , display , strings, bitmask, blurb, id, parent, ref_count, bitshift */
{ &hf_opcua_diag_mask_symbolicflag,
{ "has symbolic id", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_SYMBOLICID_FLAG, "", HFILL }
},
{ &hf_opcua_diag_mask_namespaceflag,
{ "has namespace", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_NAMESPACE_FLAG, "", HFILL }
},
{ &hf_opcua_diag_mask_localizedtextflag,
{ "has localizedtext", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_LOCALIZEDTEXT_FLAG, "", HFILL }
},
{ &hf_opcua_diag_mask_additionalinfoflag,
{ "has additional info", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_ADDITIONALINFO_FLAG, "", HFILL }
},
{ &hf_opcua_diag_mask_innerstatuscodeflag,
{ "has inner statuscode", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_INNERSTATUSCODE_FLAG, "", HFILL }
},
{ &hf_opcua_diag_mask_innerdiaginfoflag,
{ "has inner diagnostic info", "", FT_BOOLEAN, 8, NULL, DIAGNOSTICINFO_ENCODINGMASK_INNERDIAGNOSTICINFO_FLAG, "", HFILL }
},
{ &hf_opcua_loctext_mask_localeflag,
{ "has locale information", "", FT_BOOLEAN, 8, NULL, LOCALIZEDTEXT_ENCODINGBYTE_LOCALE, "", HFILL }
},
{ &hf_opcua_loctext_mask_textflag,
{ "has text", "", FT_BOOLEAN, 8, NULL, LOCALIZEDTEXT_ENCODINGBYTE_TEXT, "", HFILL }
},
{ &hf_opcua_nodeid_encodingmask,
{ "NodeId EncodingMask", "application.nodeid.encodingmask", FT_UINT8, BASE_HEX, VALS(g_nodeidmasks), 0x0, "", HFILL }
},
{ &hf_opcua_nodeid_nsid,
{ "NodeId Namespace Id", "application.nodeid.nsid", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_nodeid_numeric,
{ "NodeId Identifier Numeric", "application.nodeid.numeric", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_Locale, { "Locale", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_Text, { "Text", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_datavalue_mask_valueflag, { "has value", "", FT_BOOLEAN, 8, NULL, DATAVALUE_ENCODINGBYTE_VALUE, "", HFILL } },
{ &hf_opcua_datavalue_mask_statuscodeflag, { "has statuscode", "", FT_BOOLEAN, 8, NULL, DATAVALUE_ENCODINGBYTE_STATUSCODE, "", HFILL } },
{ &hf_opcua_datavalue_mask_sourcetimestampflag, { "has source timestamp", "", FT_BOOLEAN, 8, NULL, DATAVALUE_ENCODINGBYTE_SOURCETIMESTAMP, "", HFILL } },
{ &hf_opcua_datavalue_mask_servertimestampflag, { "has server timestamp", "", FT_BOOLEAN, 8, NULL, DATAVALUE_ENCODINGBYTE_SERVERTIMESTAMP, "", HFILL } },
{ &hf_opcua_variant_encodingmask, { "Variant Type", "", FT_UINT8, BASE_HEX, VALS(g_VariantTypes), 0x0, "", HFILL } },
{ &hf_opcua_SourceTimestamp, { "SourceTimestamp", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_ServerTimestamp, { "ServerTimestamp", "", FT_ABSOLUTE_TIME, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_diag_symbolicid, { "SymblicId", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_diag_namespace, { "Namespace", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_diag_localizedtext, { "LocaliezdText", "", FT_INT32, BASE_DEC, NULL, 0x0, "", HFILL } },
{ &hf_opcua_diag_additionalinfo, { "AdditionalInfo", "", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL } },
{ &hf_opcua_diag_innerstatuscode, { "InnerStatusCode", "", FT_UINT32, BASE_HEX, NULL, 0x0, "", HFILL } },
{ &hf_opcua_extobj_mask_binbodyflag, { "has binary body", "", FT_BOOLEAN, 8, NULL, EXTOBJ_ENCODINGMASK_BINBODY_FLAG, "", HFILL } },
{ &hf_opcua_extobj_mask_xmlbodyflag, { "has xml body", "", FT_BOOLEAN, 8, NULL, EXTOBJ_ENCODINGMASK_XMLBODY_FLAG, "", HFILL } }
};
void registerSimpleTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
proto_register_subtree_array(ett, array_length(ett));
}
void parseBoolean(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 1, TRUE); *pOffset+=1;
}
void parseByte(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 1, TRUE); *pOffset+=1;
}
void parseSByte(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 1, TRUE); *pOffset+=1;
}
void parseUInt16(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 2, TRUE); *pOffset+=2;
}
void parseInt16(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 2, TRUE); *pOffset+=2;
}
void parseUInt32(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
void parseInt32(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
void parseUInt64(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 8, TRUE); *pOffset+=8;
}
void parseInt64(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 8, TRUE); *pOffset+=8;
}
void parseString(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
char *szValue = ep_alloc(MAX_BUFFER);
gint iOffset = *pOffset;
gint32 iLen = tvb_get_letohl(tvb, *pOffset);
iOffset+=4;
if (szValue)
{
if (iLen == -1)
{
g_snprintf(szValue, MAX_BUFFER, "[OpcUa Null String]");
}
else if (iLen >= 0)
{
int iStrLen = iLen;
if (iStrLen > (MAX_BUFFER-1)) iStrLen = MAX_BUFFER - 1;
/* copy non null terminated string of length iStrlen */
strncpy(szValue, (char*)&tvb->real_data[iOffset], iStrLen);
/* set null terminator */
szValue[iStrLen] = 0;
iOffset += iLen; /* eat the whole string */
}
else
{
g_snprintf(szValue, MAX_BUFFER, "[Invalid String] Ups, something is wrong with this message.");
}
proto_tree_add_string(tree, hfIndex, tvb, *pOffset, (iOffset - *pOffset), szValue);
*pOffset = iOffset;
}
}
void parseStatusCode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, 4, TRUE);
*pOffset += 4;
}
void parseLocalizedText(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
gint iOffset = *pOffset;
guint8 EncodingMask;
proto_tree *mask_tree;
proto_tree *subtree;
proto_item *ti;
ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: LocalizedText", szFieldName);
subtree = proto_item_add_subtree(ti, ett_opcua_localizedtext);
/* parse encoding mask */
EncodingMask = tvb_get_guint8(tvb, iOffset);
ti = proto_tree_add_text(subtree, tvb, 0, -1, "EncodingMask");
mask_tree = proto_item_add_subtree(ti, ett_opcua_localizedtext);
proto_tree_add_item(mask_tree, hf_opcua_loctext_mask_localeflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_loctext_mask_textflag, tvb, iOffset, 1, TRUE);
iOffset++;
if (EncodingMask & LOCALIZEDTEXT_ENCODINGBYTE_LOCALE)
{
parseString(subtree, tvb, &iOffset, hf_opcua_Locale);
}
if (EncodingMask & LOCALIZEDTEXT_ENCODINGBYTE_TEXT)
{
parseString(subtree, tvb, &iOffset, hf_opcua_Text);
}
*pOffset = iOffset;
}
void parseGuid(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, GUID_LEN, TRUE); *pOffset+=GUID_LEN;
}
void parseByteString(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
int iOffset = *pOffset;
gint32 iLen = tvb_get_letohl(tvb, iOffset);
iOffset += 4;
if (iLen == -1)
{
}
else if (iLen >= 0)
{
iOffset += iLen;
}
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, (iOffset - *pOffset), TRUE);
*pOffset = iOffset;
}
void parseXmlElement(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
parseByteString(tree, tvb, pOffset, hfIndex);
}
void parseFloat(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, sizeof(gfloat), TRUE);
*pOffset += sizeof(gfloat);
}
void parseDouble(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
proto_tree_add_item(tree, hfIndex, tvb, *pOffset, sizeof(gdouble), TRUE);
*pOffset += sizeof(gdouble);
}
void parseDateTime(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex)
{
*pOffset = dissect_nt_64bit_time(tvb, tree, *pOffset, hfIndex);
}
void parseDiagnosticInfo(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
gint iOffset = *pOffset;
guint8 EncodingMask;
proto_tree *mask_tree;
proto_tree *subtree;
proto_item *ti;
ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: DiagnosticInfo", szFieldName);
subtree = proto_item_add_subtree(ti, ett_opcua_diagnosticinfo);
/* parse encoding mask */
EncodingMask = tvb_get_guint8(tvb, iOffset);
ti = proto_tree_add_text(subtree, tvb, 0, -1, "EncodingMask");
mask_tree = proto_item_add_subtree(ti, ett_opcua_diagnosticinfo);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_symbolicflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_namespaceflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_localizedtextflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_additionalinfoflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_innerstatuscodeflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_diag_mask_innerdiaginfoflag, tvb, iOffset, 1, TRUE);
iOffset++;
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_SYMBOLICID_FLAG)
{
parseInt32(subtree, tvb, &iOffset, hf_opcua_diag_symbolicid);
}
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_NAMESPACE_FLAG)
{
parseInt32(subtree, tvb, &iOffset, hf_opcua_diag_namespace);
}
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_LOCALIZEDTEXT_FLAG)
{
parseInt32(subtree, tvb, &iOffset, hf_opcua_diag_localizedtext);
}
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_ADDITIONALINFO_FLAG)
{
parseString(subtree, tvb, &iOffset, hf_opcua_diag_additionalinfo);
}
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_INNERSTATUSCODE_FLAG)
{
parseStatusCode(subtree, tvb, &iOffset, hf_opcua_diag_innerstatuscode);
}
if (EncodingMask & DIAGNOSTICINFO_ENCODINGMASK_INNERDIAGNOSTICINFO_FLAG)
{
parseDiagnosticInfo(subtree, tvb, &iOffset, "Inner DiagnosticInfo");
}
*pOffset = iOffset;
}
void parseQualifiedName(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: QualifiedName", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_qualifiedname);
parseInt32(subtree, tvb, pOffset, hf_opcua_Id);
parseString(subtree, tvb, pOffset, hf_opcua_Name);
}
void parseDataValue(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: DataValue", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_datavalue);
proto_tree *mask_tree;
gint iOffset = *pOffset;
guint8 EncodingMask;
EncodingMask = tvb_get_guint8(tvb, iOffset);
ti = proto_tree_add_text(subtree, tvb, 0, -1, "EncodingMask");
mask_tree = proto_item_add_subtree(ti, ett_opcua_datavalue);
proto_tree_add_item(mask_tree, hf_opcua_datavalue_mask_valueflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_datavalue_mask_statuscodeflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_datavalue_mask_sourcetimestampflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_datavalue_mask_servertimestampflag, tvb, iOffset, 1, TRUE);
iOffset++;
if (EncodingMask & DATAVALUE_ENCODINGBYTE_VALUE)
{
parseVariant(subtree, tvb, &iOffset, "Value");
}
if (EncodingMask & DATAVALUE_ENCODINGBYTE_STATUSCODE)
{
parseStatusCode(subtree, tvb, &iOffset, hf_opcua_StatusCode);
}
if (EncodingMask & DATAVALUE_ENCODINGBYTE_SOURCETIMESTAMP)
{
parseDateTime(subtree, tvb, &iOffset, hf_opcua_SourceTimestamp);
}
if (EncodingMask & DATAVALUE_ENCODINGBYTE_SERVERTIMESTAMP)
{
parseDateTime(subtree, tvb, &iOffset, hf_opcua_ServerTimestamp);
}
*pOffset = iOffset;
}
void parseVariant(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: Variant", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_variant);
gint iOffset = *pOffset;
guint8 EncodingMask;
EncodingMask = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_variant_encodingmask, tvb, iOffset, 1, TRUE);
iOffset++;
if (EncodingMask & VARIANT_ARRAYMASK)
{
EncodingMask &= ~VARIANT_ARRAYMASK;
switch(EncodingMask)
{
case OpcUaType_Null: break;
case OpcUaType_Boolean: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Boolean, parseBoolean); break;
case OpcUaType_SByte: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_SByte, parseSByte); break;
case OpcUaType_Byte: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Byte, parseByte); break;
case OpcUaType_Int16: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Int16, parseInt16); break;
case OpcUaType_UInt16: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_UInt16, parseUInt16); break;
case OpcUaType_Int32: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Int32, parseInt32); break;
case OpcUaType_UInt32: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_UInt32, parseUInt32); break;
case OpcUaType_Int64: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Int64, parseInt64); break;
case OpcUaType_UInt64: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_UInt64, parseUInt64); break;
case OpcUaType_Float: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Float, parseFloat); break;
case OpcUaType_Double: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Double, parseDouble); break;
case OpcUaType_String: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_String, parseString); break;
case OpcUaType_DateTime: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_DateTime, parseDateTime); break;
case OpcUaType_Guid: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_Guid, parseGuid); break;
case OpcUaType_ByteString: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_ByteString, parseByteString); break;
case OpcUaType_XmlElement: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_XmlElement, parseXmlElement); break;
case OpcUaType_NodeId: parseArrayComplex(subtree, tvb, &iOffset, "NodeId", parseNodeId); break;
case OpcUaType_ExpandedNodeId: parseArrayComplex(subtree, tvb, &iOffset, "ExpandedNodeId", parseExpandedNodeId); break;
case OpcUaType_StatusCode: parseArraySimple(subtree, tvb, &iOffset, hf_opcua_StatusCode, parseStatusCode); break;
case OpcUaType_DiagnosticInfo: parseArrayComplex(subtree, tvb, &iOffset, "DiagnosticInfo", parseDiagnosticInfo); break;
case OpcUaType_QualifiedName: parseArrayComplex(subtree, tvb, &iOffset, "QualifiedName", parseQualifiedName); break;
case OpcUaType_LocalizedText: parseArrayComplex(subtree, tvb, &iOffset, "LocalizedText", parseLocalizedText); break;
case OpcUaType_ExtensionObject: parseArrayComplex(subtree, tvb, &iOffset, "ExtensionObject", parseExtensionObject); break;
case OpcUaType_DataValue: parseArrayComplex(subtree, tvb, &iOffset, "DataValue", parseDataValue); break;
case OpcUaType_Variant: parseArrayComplex(subtree, tvb, &iOffset, "Variant", parseVariant); break;
}
}
else
{
switch(EncodingMask)
{
case OpcUaType_Null: break;
case OpcUaType_Boolean: parseBoolean(subtree, tvb, &iOffset, hf_opcua_Boolean); break;
case OpcUaType_SByte: parseSByte(subtree, tvb, &iOffset, hf_opcua_SByte); break;
case OpcUaType_Byte: parseByte(subtree, tvb, &iOffset, hf_opcua_Byte); break;
case OpcUaType_Int16: parseInt16(subtree, tvb, &iOffset, hf_opcua_Int16); break;
case OpcUaType_UInt16: parseUInt16(subtree, tvb, &iOffset, hf_opcua_UInt16); break;
case OpcUaType_Int32: parseInt32(subtree, tvb, &iOffset, hf_opcua_Int32); break;
case OpcUaType_UInt32: parseUInt32(subtree, tvb, &iOffset, hf_opcua_UInt32); break;
case OpcUaType_Int64: parseInt64(subtree, tvb, &iOffset, hf_opcua_Int64); break;
case OpcUaType_UInt64: parseUInt64(subtree, tvb, &iOffset, hf_opcua_UInt64); break;
case OpcUaType_Float: parseFloat(subtree, tvb, &iOffset, hf_opcua_Float); break;
case OpcUaType_Double: parseDouble(subtree, tvb, &iOffset, hf_opcua_Double); break;
case OpcUaType_String: parseString(subtree, tvb, &iOffset, hf_opcua_String); break;
case OpcUaType_DateTime: parseDateTime(subtree, tvb, &iOffset, hf_opcua_DateTime); break;
case OpcUaType_Guid: parseGuid(subtree, tvb, &iOffset, hf_opcua_Guid); break;
case OpcUaType_ByteString: parseByteString(subtree, tvb, &iOffset, hf_opcua_ByteString); break;
case OpcUaType_XmlElement: parseXmlElement(subtree, tvb, &iOffset, hf_opcua_XmlElement); break;
case OpcUaType_NodeId: parseNodeId(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_ExpandedNodeId: parseExpandedNodeId(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_StatusCode: parseStatusCode(subtree, tvb, &iOffset, hf_opcua_StatusCode); break;
case OpcUaType_DiagnosticInfo: parseDiagnosticInfo(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_QualifiedName: parseQualifiedName(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_LocalizedText: parseLocalizedText(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_ExtensionObject: parseExtensionObject(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_DataValue: parseDataValue(subtree, tvb, &iOffset, "Value"); break;
case OpcUaType_Variant: parseVariant(subtree, tvb, &iOffset, "Value"); break;
}
}
*pOffset = iOffset;
}
/** General parsing function for arrays of simple types.
* All arrays have one 4 byte signed integer length information,
* followed by n data elements.
*/
void parseArraySimple(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex, fctSimpleTypeParser pParserFunction)
{
char szFieldName[] = "Array of Simple Type";
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_array);
int i;
gint32 iLen;
/* read array length */
iLen = tvb_get_letohl(tvb, *pOffset);
proto_tree_add_item(subtree, hf_opcua_ArraySize, tvb, *pOffset, 4, TRUE);
*pOffset += 4;
if (iLen == -1) return; /* no array */
if (iLen == 0) return; /* array with zero elements*/
for (i=0; i<iLen; i++)
{
(*pParserFunction)(subtree, tvb, pOffset, hfIndex);
}
}
/** General parsing function for arrays of enums.
* All arrays have one 4 byte signed integer length information,
* followed by n data elements.
*/
void parseArrayEnum(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, fctEnumParser pParserFunction)
{
char szFieldName[] = "Array of Enum Type";
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_array);
int i;
gint32 iLen;
/* read array length */
iLen = tvb_get_letohl(tvb, *pOffset);
proto_tree_add_item(subtree, hf_opcua_ArraySize, tvb, *pOffset, 4, TRUE);
*pOffset += 4;
if (iLen == -1) return; /* no array */
if (iLen == 0) return; /* array with zero elements*/
for (i=0; i<iLen; i++)
{
(*pParserFunction)(subtree, tvb, pOffset);
}
}
/** General parsing function for arrays of complex types.
* All arrays have one 4 byte signed integer length information,
* followed by n data elements.
*/
void parseArrayComplex(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName, fctComplexTypeParser pParserFunction)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "Array of %s", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_array);
int i;
gint32 iLen;
/* read array length */
iLen = tvb_get_letohl(tvb, *pOffset);
proto_tree_add_item(subtree, hf_opcua_ArraySize, tvb, *pOffset, 4, TRUE);
*pOffset += 4;
if (iLen == -1) return; /* no array */
if (iLen == 0) return; /* array with zero elements*/
for (i=0; i<iLen; i++)
{
char szNum[20];
g_snprintf(szNum, 20, "[%i]", i);
(*pParserFunction)(subtree, tvb, pOffset, szNum);
}
}
void parseNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: NodeId", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_nodeid);
gint iOffset = *pOffset;
guint8 EncodingMask;
guint32 Numeric = 0, NSId = 0;
EncodingMask = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_encodingmask, tvb, iOffset, 1, TRUE);
iOffset++;
switch(EncodingMask)
{
case 0x00: /* two byte node id */
Numeric = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 1, TRUE);
iOffset+=1;
break;
case 0x01: /* four byte node id */
NSId = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 1, TRUE);
iOffset+=1;
Numeric = tvb_get_letohs(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 2, TRUE);
iOffset+=2;
break;
case 0x02: /* numeric, that does not fit into four bytes */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
Numeric = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 4, TRUE);
iOffset+=4;
break;
case 0x03: /* string */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
parseString(subtree, tvb, &iOffset, hf_opcua_String);
break;
case 0x04: /* uri */
parseString(subtree, tvb, &iOffset, hf_opcua_Uri);
break;
case 0x05: /* guid */
parseGuid(subtree, tvb, &iOffset, hf_opcua_Guid);
break;
case 0x06: /* byte string */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
parseByteString(subtree, tvb, &iOffset, hf_opcua_ByteString);
break;
};
*pOffset = iOffset;
}
void parseExtensionObject(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
gint iOffset = *pOffset;
guint8 EncodingMask;
proto_tree *extobj_tree;
proto_tree *mask_tree;
proto_item *ti;
/* add extension object subtree */
ti = proto_tree_add_text(tree, tvb, 0, -1, "%s : ExtensionObject", szFieldName);
extobj_tree = proto_item_add_subtree(ti, ett_opcua_extensionobject);
/* add nodeid subtree */
parseExpandedNodeId(extobj_tree, tvb, &iOffset, "TypeId");
/* parse encoding mask */
EncodingMask = tvb_get_guint8(tvb, iOffset);
ti = proto_tree_add_text(extobj_tree, tvb, 0, -1, "EncodingMask");
mask_tree = proto_item_add_subtree(ti, ett_opcua_extobj_encodingmask);
proto_tree_add_item(mask_tree, hf_opcua_extobj_mask_binbodyflag, tvb, iOffset, 1, TRUE);
proto_tree_add_item(mask_tree, hf_opcua_extobj_mask_xmlbodyflag, tvb, iOffset, 1, TRUE);
iOffset++;
if (EncodingMask & EXTOBJ_ENCODINGMASK_BINBODY_FLAG) /* has binary body ? */
{
parseByteString(extobj_tree, tvb, &iOffset, hf_opcua_ByteString);
}
*pOffset = iOffset;
}
void parseExpandedNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
proto_item *ti = proto_tree_add_text(tree, tvb, 0, -1, "%s: ExpandedNodeId", szFieldName);
proto_tree *subtree = proto_item_add_subtree(ti, ett_opcua_nodeid);
gint iOffset = *pOffset;
guint8 EncodingMask, NSId = 0;
guint32 Numeric = 0;
EncodingMask = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_encodingmask, tvb, iOffset, 1, TRUE);
iOffset++;
switch(EncodingMask)
{
case 0x00: /* two byte node id */
Numeric = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 1, TRUE);
iOffset+=1;
break;
case 0x01: /* four byte node id */
NSId = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 1, TRUE);
iOffset+=1;
Numeric = tvb_get_letohs(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 2, TRUE);
iOffset+=2;
break;
case 0x02: /* numeric, that does not fit into four bytes */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
Numeric = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_numeric, tvb, iOffset, 4, TRUE);
iOffset+=4;
break;
case 0x03: /* string */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
parseString(subtree, tvb, &iOffset, hf_opcua_String);
break;
case 0x04: /* uri */
parseString(subtree, tvb, &iOffset, hf_opcua_Uri);
break;
case 0x05: /* guid */
parseGuid(subtree, tvb, &iOffset, hf_opcua_Guid);
break;
case 0x06: /* byte string */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(subtree, hf_opcua_nodeid_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
parseByteString(subtree, tvb, &iOffset, hf_opcua_ByteString);
break;
};
if (EncodingMask & NODEID_URIMASK)
{
parseString(subtree, tvb, &iOffset, hf_opcua_Uri);
}
*pOffset = iOffset;
}

View File

@ -0,0 +1,56 @@
/******************************************************************************
** $Id: opcua_simpletypes.h,v 1.1 2007/02/08 11:26:55 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: Implementation of OpcUa built-in type parsers.
** This contains all the simple types and some complex types.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#include "opcua_identifiers.h"
/* simple types */
void parseBoolean(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseByte(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseSByte(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseUInt16(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseInt16(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseUInt32(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseInt32(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseUInt64(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseInt64(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseString(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseGuid(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseByteString(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseXmlElement(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseFloat(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseDouble(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseDateTime(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
void parseStatusCode(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex);
/* complex types */
void parseLocalizedText(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDiagnosticInfo(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseExtensionObject(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseQualifiedName(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseDataValue(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseVariant(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseExpandedNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);
void parseArraySimple(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int hfIndex, fctSimpleTypeParser pParserFunction);
void parseArrayEnum(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, fctEnumParser pParserFunction);
void parseArrayComplex(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName, fctComplexTypeParser pParserFunction);
void registerSimpleTypes(int proto);

26
plugins/opcua/plugin.c Normal file
View File

@ -0,0 +1,26 @@
/* Do not modify this file. */
/* It is created automatically by the Makefile. */
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include "moduleinfo.h"
#ifndef ENABLE_STATIC
G_MODULE_EXPORT const gchar version[] = VERSION;
/* Start the functions we need for the plugin stuff */
G_MODULE_EXPORT void
plugin_register (void)
{
{extern void proto_register_opcua (void); proto_register_opcua ();}
}
G_MODULE_EXPORT void
plugin_reg_handoff(void)
{
{extern void proto_reg_handoff_opcua (void); proto_reg_handoff_opcua ();}
}
#endif

View File

@ -0,0 +1,122 @@
/******************************************************************************
** $Id: ua_application_layer.c,v 1.3 2007/02/08 11:31:56 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Application Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "opcua_simpletypes.h"
/** NodeId encoding mask table */
static const value_string g_nodeidmasks[] = {
{ 0, "Two byte encoded Numeric" },
{ 1, "Four byte encoded Numeric" },
{ 2, "Numeric of arbitrary length" },
{ 3, "String" },
{ 4, "URI" },
{ 5, "GUID" },
{ 6, "ByteString" },
{ 0x80, "UriMask" },
{ 0, NULL }
};
/** Service type table */
extern const value_string g_requesttypes[];
static int hf_opcua_nodeid_encodingmask = -1;
static int hf_opcua_app_nsid = -1;
static int hf_opcua_app_numeric = -1;
/** header field definitions */
static hf_register_info hf[] =
{
{ &hf_opcua_nodeid_encodingmask,
{ "NodeId EncodingMask", "application.nodeid.encodingmask", FT_UINT8, BASE_HEX, VALS(g_nodeidmasks), 0x0, "", HFILL }
},
{ &hf_opcua_app_nsid,
{ "NodeId EncodingMask", "application.nodeid.nsid", FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_app_numeric,
{ "NodeId Identifier Numeric", "application.nodeid.numeric", FT_UINT32, BASE_DEC, VALS(g_requesttypes), 0x0, "", HFILL }
}
};
/** Register application layer types. */
void registerApplicationLayerTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
}
/** Parses an OpcUa Service NodeId and returns the service type.
* In this cases the NodeId is always from type numeric and NSId = 0.
*/
int parseServiceNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName)
{
gint iOffset = *pOffset;
guint8 EncodingMask, NSId = 0;
guint32 Numeric = 0;
szFieldName = 0; /* avoid warning */
EncodingMask = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_nodeid_encodingmask, tvb, iOffset, 1, TRUE);
iOffset++;
switch(EncodingMask)
{
case 0x00: /* two byte node id */
Numeric = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_app_numeric, tvb, iOffset, 1, TRUE);
iOffset+=1;
break;
case 0x01: /* four byte node id */
NSId = tvb_get_guint8(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_app_nsid, tvb, iOffset, 1, TRUE);
iOffset+=1;
Numeric = tvb_get_letohs(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_app_numeric, tvb, iOffset, 2, TRUE);
iOffset+=2;
break;
case 0x02: /* numeric, that does not fit into four bytes */
NSId = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_app_nsid, tvb, iOffset, 4, TRUE);
iOffset+=4;
Numeric = tvb_get_letohl(tvb, iOffset);
proto_tree_add_item(tree, hf_opcua_app_numeric, tvb, iOffset, 4, TRUE);
iOffset+=4;
break;
case 0x03: /* string */
case 0x04: /* uri */
case 0x05: /* guid */
case 0x06: /* byte string */
/* NOT USED */
break;
};
*pOffset = iOffset;
return Numeric;
}

View File

@ -0,0 +1,27 @@
/******************************************************************************
** $Id: ua_application_layer.h,v 1.3 2007/02/08 12:19:58 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Application Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
void registerApplicationLayerTypes(int proto);
/* Ua type parsers */
int parseServiceNodeId(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, char *szFieldName);

View File

@ -0,0 +1,99 @@
/******************************************************************************
** $Id: ua_security_layer.c,v 1.2 2007/02/08 12:16:59 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Security Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "ua_application_layer.h"
#include "opcua_simpletypes.h"
/** NodeClass enum table */
static const value_string g_SecSigTable[] = {
{ 0, "GetSecurityPolcies" },
{ 1, "OpenSecureChannel" },
{ 2, "CloseSecureChannel" },
{ 3, "Message" },
{ 0, NULL }
};
static int hf_opcua_SecuritySigEnum = -1;
static int hf_opcua_security_sig = -1;
static int hf_opcua_security_policy = -1;
static int hf_opcua_security_channel = -1;
static int hf_opcua_security_token = -1;
static hf_register_info hf[] =
{
{ &hf_opcua_security_sig,
{ "Security Signature", "security.sig", FT_UINT16, BASE_HEX, VALS(g_SecSigTable), 0x0, "", HFILL }
},
{ &hf_opcua_security_policy,
{ "Security Policy", "security.policy", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_security_channel,
{ "Secure Channel Id", "security.channel", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_security_token,
{ "Security Token Id", "security.token", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL }
}
};
/** Register security layer types. */
void registerSecurityLayerTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
}
/* Security Layer: message parsers
* Only works for Security Policy "NoSecurity" at the moment.
*/
void parseSecurityLayer(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
guint16 Sig;
Sig = tvb_get_letohs(tvb, pOffset[0]);
proto_tree_add_item(tree, hf_opcua_security_sig, tvb, *pOffset, 2, TRUE); *pOffset+=2;
switch (Sig)
{
case 0: /* GetSecurityPolicies */
break;
case 1: /* OpenSecureChannel */
parseGuid(tree, tvb, pOffset, hf_opcua_security_channel);
parseString(tree, tvb, pOffset, hf_opcua_security_policy);
break;
case 2: /* CloseSecureChannel */
parseGuid(tree, tvb, pOffset, hf_opcua_security_channel);
parseString(tree, tvb, pOffset, hf_opcua_security_token);
break;
case 3: /* Other Services Messages */
parseGuid(tree, tvb, pOffset, hf_opcua_security_channel);
parseString(tree, tvb, pOffset, hf_opcua_security_token);
break;
}
}

View File

@ -0,0 +1,25 @@
/******************************************************************************
** $Id: ua_security_layer.h,v 1.2 2007/02/08 12:19:58 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Security Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
void registerSecurityLayerTypes(int proto);
void parseSecurityLayer(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);

View File

@ -0,0 +1,211 @@
/******************************************************************************
** $Id: ua_transport_layer.c,v 1.3 2007/02/08 12:17:50 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Transport Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <gmodule.h>
#include <epan/packet.h>
#include "ua_security_layer.h"
#include "ua_application_layer.h"
#include "opcua_simpletypes.h"
#include <string.h>
#include <epan/emem.h>
void dispatchService(proto_tree *tree, tvbuff_t *tvb, gint *pOffset, int ServiceId);
static int hf_opcua_transport_sig = -1;
static int hf_opcua_transport_len = -1;
static int hf_opcua_transport_ver = -1;
static int hf_opcua_transport_cid = -1;
static int hf_opcua_transport_lifetime = -1;
static int hf_opcua_transport_sbl = -1;
static int hf_opcua_transport_rbl = -1;
static int hf_opcua_transport_endpoint = -1;
static int hf_opcua_transport_rlifetime = -1;
static int hf_opcua_transport_rsbl = -1;
static int hf_opcua_transport_rrbl = -1;
static int hf_opcua_transport_altendpoint = -1;
static int hf_opcua_transport_rqid = -1;
static int hf_opcua_transport_status = -1;
extern gint ett_opcua_nodeid;
static hf_register_info hf[] =
{
{ &hf_opcua_transport_sig,
/* full name , abbreviation , type , display , strings, bitmask, blurb, id, parent, ref_count, bitshift */
{ "Signature", "transport.sig", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_len,
{ "Message Length", "transport.len", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_ver,
{ "Version", "transport.ver", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_cid,
{ "ConnectionId", "transport.cid", FT_GUID, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_lifetime,
{ "Lifetime", "transport.lifetime", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_sbl,
{ "SendBufferLength", "transport.sbl", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_rbl,
{ "ReceiveBufferLength", "transport.rbl", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_endpoint,
{ "EndPoint", "transport.endpoint", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_rlifetime,
{ "Revised Lifetime", "transport.rlifetime", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_rsbl,
{ "Revised SendBufferLength", "transport.rsbl", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_rrbl,
{ "Revised ReceiveBufferLength", "transport.rrbl", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_altendpoint,
{ "Alternate EndPoint", "transport.altendpoint", FT_STRING, BASE_NONE, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_rqid,
{ "RequestId", "transport.rqid", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
},
{ &hf_opcua_transport_status,
{ "StatusCode", "transport.status", FT_UINT32, BASE_DEC, NULL, 0x0, "", HFILL }
}
};
/** subtree types */
extern gint ett_opcua_extensionobject;
/** Register transport layer types. */
void registerTransportLayerTypes(int proto)
{
proto_register_field_array(proto, hf, array_length(hf));
}
/** helper functions for adding strings,
* that are not zero terminated.
*/
void addString(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
gint start,
gint length,
const char *value)
{
char *szValue = ep_alloc(256);
if (szValue)
{
if (length > 255) length = 255;
/* copy non null terminated string data */
strncpy(szValue, value, length);
/* set null terminator */
szValue[length] = 0;
proto_tree_add_string(tree, hfindex, tvb, start, length, szValue);
}
}
/* Transport Layer: message parsers */
void parseHello(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_ver, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
proto_tree_add_item(tree, hf_opcua_transport_lifetime, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_sbl, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_rbl, tvb, *pOffset, 4, TRUE); *pOffset+=4;
parseString(tree, tvb, pOffset, hf_opcua_transport_endpoint);
}
void parseAcknowledge(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
proto_tree_add_item(tree, hf_opcua_transport_rlifetime, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_rsbl, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_rrbl, tvb, *pOffset, 4, TRUE); *pOffset+=4;
parseString(tree, tvb, pOffset, hf_opcua_transport_altendpoint);
}
void parseDisconnect(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
}
void parseData(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
proto_item *ti;
proto_tree *encobj_tree;
proto_tree *nodeid_tree;
int ServiceId = 0;
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
proto_tree_add_item(tree, hf_opcua_transport_rqid, tvb, *pOffset, 4, TRUE); *pOffset+=4;
/* message data contains the security layer */
parseSecurityLayer(tree, tvb, pOffset);
/* AT THE MOMENT NO SECURITY IS IMPLEMENTED IN UA.
* WE CAN JUST JUMP INTO THE APPLICATION LAYER DATA.
* THIS WILL CHAHNGE IN THE FUTURE. */
/* add encodeable object subtree */
ti = proto_tree_add_text(tree, tvb, 0, -1, "Message : Encodeable Object");
encobj_tree = proto_item_add_subtree(ti, ett_opcua_extensionobject);
/* add nodeid subtree */
ti = proto_tree_add_text(encobj_tree, tvb, 0, -1, "TypeId : ExpandedNodeId");
nodeid_tree = proto_item_add_subtree(ti, ett_opcua_nodeid);
ServiceId = parseServiceNodeId(nodeid_tree, tvb, pOffset, "NodeId") - 1;
dispatchService(encobj_tree, tvb, pOffset, ServiceId);
}
void parseAbort(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
proto_tree_add_item(tree, hf_opcua_transport_rqid, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}
void parseError(proto_tree *tree, tvbuff_t *tvb, gint *pOffset)
{
addString(tree, hf_opcua_transport_sig, tvb, *pOffset, 4, tvb->real_data); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_len, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_cid, tvb, *pOffset, 16, TRUE); *pOffset+=16;
proto_tree_add_item(tree, hf_opcua_transport_rqid, tvb, *pOffset, 4, TRUE); *pOffset+=4;
proto_tree_add_item(tree, hf_opcua_transport_status, tvb, *pOffset, 4, TRUE); *pOffset+=4;
}

View File

@ -0,0 +1,32 @@
/******************************************************************************
** $Id: ua_transport_layer.h,v 1.3 2007/02/08 12:19:58 gergap Exp $
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Transport Layer Decoder.
**
** Author: Gerhard Gappmeier <gerhard.gappmeier@ascolab.com>
** Last change by: $Author: gergap $
**
******************************************************************************/
/* Transport Layer: message parsers */
void parseHello(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAcknowledge(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseDisconnect(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseData(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseAbort(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void parseError(proto_tree *tree, tvbuff_t *tvb, gint *pOffset);
void registerTransportLayerTypes(int proto);