Class GetChannelAuthenticationCapabilities
java.lang.Object
org.metricshub.ipmi.core.coding.PayloadCoder
org.metricshub.ipmi.core.coding.commands.IpmiCommandCoder
org.metricshub.ipmi.core.coding.commands.session.GetChannelAuthenticationCapabilities
Wrapper for Get Channel Authentication Capabilities request
-
Constructor Summary
ConstructorsConstructorDescriptionInitiates class for decoding in 1.5 version.GetChannelAuthenticationCapabilities
(IpmiVersion version, IpmiVersion requestVersion, CipherSuite cipherSuite) Initiates class.GetChannelAuthenticationCapabilities
(IpmiVersion version, IpmiVersion requestVersion, CipherSuite cipherSuite, PrivilegeLevel privilegeLevel, byte channelNumber) Initiates class. -
Method Summary
Modifier and TypeMethodDescriptionencodePayload
(int messageSequenceNumber, int sessionSequenceNumber, int sessionId) Prepares an IPMI request message containing class-specific payload.int
byte
Retrieves command code specific for command represented by this classRetrieves network function specific for command represented by this class.getResponseData
(IpmiMessage message) Retrieves payload-specific response data from IPMI messagevoid
setChannelNumber
(int channelNumber) Sets the channel number that will be put into IPMI command.void
setRequestedPrivilegeLevel
(PrivilegeLevel requestedPrivilegeLevel) void
setSessionParameters
(IpmiVersion version, CipherSuite cipherSuite, AuthenticationType authenticationType) Sets session parameters.Methods inherited from class org.metricshub.ipmi.core.coding.commands.IpmiCommandCoder
getSupportedPayloadType, isCommandResponse
Methods inherited from class org.metricshub.ipmi.core.coding.PayloadCoder
getAuthenticationType, getCipherSuite, getIpmiVersion, setAuthenticationType, setCipherSuite, setIpmiVersion
-
Constructor Details
-
GetChannelAuthenticationCapabilities
public GetChannelAuthenticationCapabilities()Initiates class for decoding in 1.5 version. Sets requested privilege level to user. Sets channel number to 14 indicating that response will contain information for channel this request was issued on. Sets session parameters to default. -
GetChannelAuthenticationCapabilities
public GetChannelAuthenticationCapabilities(IpmiVersion version, IpmiVersion requestVersion, CipherSuite cipherSuite) Initiates class. Sets IPMI version to version. Sets requested privilege level to user. Sets channel number to 14 indicating that response will contain information for channel this request was issued on.- Parameters:
version
- - Version of IPMI protocol usedrequestVersion
- - If Get Channel Authentication Capabilities command is sent to BMC with requestVersion =IpmiVersion.V15
it will respond, that it does not support IPMI v2.0 even if it does.cipherSuite
- -CipherSuite
containing authentication, confidentiality and integrity algorithms for this session.- See Also:
-
GetChannelAuthenticationCapabilities
public GetChannelAuthenticationCapabilities(IpmiVersion version, IpmiVersion requestVersion, CipherSuite cipherSuite, PrivilegeLevel privilegeLevel, byte channelNumber) Initiates class. Sets IPMI version to version. Sets requested privilege level privilegeLevel. Sets channel number to channelNumber.- Parameters:
version
- - Version of IPMI protocol usedrequestVersion
- - If Get Channel Authentication Capabilities command is sent to BMC with requestVersion =IpmiVersion.V15
it will respond, that it does not support IPMI v2.0 even if it does.cipherSuite
- -CipherSuite
containing authentication, confidentiality and integrity algorithms for this session.privilegeLevel
- - Maximum requested privilege level. Can't bePrivilegeLevel.MaximumAvailable
.channelNumber
- - must be 0h-Bh or Eh-Fh
Eh = retrieve information for channel this request was issued on.- See Also:
-
-
Method Details
-
setRequestedPrivilegeLevel
-
getRequestedPrivilegeLevel
-
setChannelNumber
public void setChannelNumber(int channelNumber) Sets the channel number that will be put into IPMI command.- Parameters:
channelNumber
- - must be 0h-Bh or Eh-Fh
Eh = retrieve information for channel this request was issued on- Throws:
IllegalArgumentException
-
getChannelNumber
public int getChannelNumber() -
encodePayload
public IpmiMessage encodePayload(int messageSequenceNumber, int sessionSequenceNumber, int sessionId) throws InvalidKeyException, NoSuchAlgorithmException Description copied from class:PayloadCoder
Prepares an IPMI request message containing class-specific payload.- Overrides:
encodePayload
in classPayloadCoder
- Parameters:
messageSequenceNumber
- - A generated sequence number used for matching request and response. For all IPMI messages, messageSequenceNumber is used as a IPMI LAN Message sequence number and as an IPMI payload message tag.sessionSequenceNumber
- - If IPMI message is sent in a session, it is used as a Session Sequence NumbersessionId
- - ID of the managed system's session message is being sent in. For sessionless commands should b set to 0.- Returns:
- IPMI message
- Throws:
InvalidKeyException
- - when creating of the algorithm key failsNoSuchAlgorithmException
- - when authentication, confidentiality or integrity algorithm fails.
-
getCommandCode
public byte getCommandCode()Description copied from class:IpmiCommandCoder
Retrieves command code specific for command represented by this class- Specified by:
getCommandCode
in classIpmiCommandCoder
- Returns:
- command code
-
getNetworkFunction
Description copied from class:IpmiCommandCoder
Retrieves network function specific for command represented by this class.- Specified by:
getNetworkFunction
in classIpmiCommandCoder
- Returns:
- network function
- See Also:
-
getResponseData
Description copied from class:PayloadCoder
Retrieves payload-specific response data from IPMI message- Specified by:
getResponseData
in classPayloadCoder
- Parameters:
message
- - IPMI message- Returns:
- response data
- Throws:
IPMIException
- when response completion code isn't OK.
-
setSessionParameters
public void setSessionParameters(IpmiVersion version, CipherSuite cipherSuite, AuthenticationType authenticationType) Sets session parameters.- Overrides:
setSessionParameters
in classPayloadCoder
- Parameters:
version
- - IPMI version of the command.cipherSuite
- -CipherSuite
containing authentication, confidentiality and integrity algorithms for this session.authenticationType
- - Type of authentication used. Must be RMCPPlus for IPMI v2.0.
-