Path: blob/aarch64-shenandoah-jdk8u272-b10/jdk/src/share/classes/com/sun/jmx/snmp/SnmpScopedPduPacket.java
38924 views
/*1* Copyright (c) 2001, 2003, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation. Oracle designates this7* particular file as subject to the "Classpath" exception as provided8* by Oracle in the LICENSE file that accompanied this code.9*10* This code is distributed in the hope that it will be useful, but WITHOUT11* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or12* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License13* version 2 for more details (a copy is included in the LICENSE file that14* accompanied this code).15*16* You should have received a copy of the GNU General Public License version17* 2 along with this work; if not, write to the Free Software Foundation,18* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.19*20* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA21* or visit www.oracle.com if you need additional information or have any22* questions.23*/2425package com.sun.jmx.snmp;2627import java.io.Serializable;2829import com.sun.jmx.snmp.SnmpSecurityParameters;3031import com.sun.jmx.snmp.SnmpDefinitions;32/**33* Is the fully decoded representation of an SNMP V3 packet.34* <P>35*36* Classes are derived from <CODE>SnmpPdu</CODE> to37* represent the different forms of SNMP pdu38* ({@link com.sun.jmx.snmp.SnmpScopedPduRequest SnmpScopedPduRequest},39* {@link com.sun.jmx.snmp.SnmpScopedPduBulk SnmpScopedPduBulk}).40* <BR>The <CODE>SnmpScopedPduPacket</CODE> class defines the attributes41* common to every scoped SNMP packets.42*43* <p><b>This API is a Sun Microsystems internal API and is subject44* to change without notice.</b></p>45* @see SnmpV3Message46*47* @since 1.548*/49public abstract class SnmpScopedPduPacket extends SnmpPdu50implements Serializable {51/**52* Message max size the pdu sender can deal with.53*/54public int msgMaxSize = 0;5556/**57* Message identifier.58*/59public int msgId = 0;6061/**62* Message flags. Reportable flag and security level.</P>63*<PRE>64* -- .... ...1 authFlag65* -- .... ..1. privFlag66* -- .... .1.. reportableFlag67* -- Please observe:68* -- .... ..00 is OK, means noAuthNoPriv69* -- .... ..01 is OK, means authNoPriv70* -- .... ..10 reserved, must NOT be used.71* -- .... ..11 is OK, means authPriv72*</PRE>73*/74public byte msgFlags = 0;7576/**77* The security model the security sub system MUST use in order to deal with this pdu (eg: User based Security Model Id = 3).78*/79public int msgSecurityModel = 0;8081/**82* The context engine Id in which the pdu must be handled (Generaly the local engine Id).83*/84public byte[] contextEngineId = null;8586/**87* The context name in which the OID have to be interpreted.88*/89public byte[] contextName = null;9091/**92* The security parameters. This is an opaque member that is93* interpreted by the concerned security model.94*/95public SnmpSecurityParameters securityParameters = null;9697/**98* Constructor. Is only called by a son. Set the version to <CODE>SnmpDefinitions.snmpVersionThree</CODE>.99*/100protected SnmpScopedPduPacket() {101version = SnmpDefinitions.snmpVersionThree;102}103}104105106