WifiConfig_NetworkDiagnostics struct

Header: #include <applibs/wificonfig.h>

Information about the most recent failure to connect to a network.

Note

This is an alias to a versioned structure. Define WIFICONFIG_STRUCTS_VERSION to use this alias.

typedef struct WifiConfig_NetworkDiagnostics {

    uint8_t isEnabled;
    uint8_t isConnected;
    int32_t error;
    time_t timestamp;
    int32_t certError;
    int32_t certDepth;
    CertStore_SubjectName certSubject;
} WifiConfig_NetworkDiagnostics;

Members

uint8_t isEnabled

Indicates whether the network is enabled. The value is 1 if enabled and 0 if not enabled. This field indicates the current state of the network, not the state of the configuration. The value will be 0 if the network is temporarily disabled.

uint8_t isConnected

Indicates whether the network is connected. The value is 1 if connected and 0 if not connected.

int32_t error

The reason for the most recent failure to connect to this network. Possible values:

Type Value Meaning
ConnectionFailed 1 Generic error message when connection fails. For EAP-TLS networks, this error is potentially caused by not being able to reach the RADIUS server or using a client identity the RADIUS server does not recognize.
NetworkNotFound 2 Network was not found.
NoPskIncluded 3 Network password is missing.
WrongKey 4 Network is using an incorrect password.
AuthenticationFailed 5 Authentication failed. This error applies only to EAP-TLS networks.
SecurityTypeMismatch 6 The stored network's security type does not match the available network.
NetworkFrequencyNotAllowed 7 Network frequency not allowed.
NetworkNotEssPbssMbss 8 Network is not supported because no Extended Service Set (ESS), Personal Basic Service Set (PBSS),or Minimum Baseline Security Standard (MBSS) was detected.
NetworkNotSupported 9 Network is not supported.
NetworkNonWpa 10 Network is not WPA2PSK, WPA2EAP, or Open.

time_t timestamp

The OS time at which the error was recorded.

int32_t certError

The certificate error, meaningful only when error indicates AuthenticationFailed. Note: There may be conditions where certError may not return an error.

Possible values:

   ERRID                          Potential Problem
   Unspecified = 0:               Generic error message when certificate validation fails.
   Certificate Not Found = 100:   This could be due to an incorrect certificate specified when configuring the EAP-TLS network, or ReloadConfig() was not called after loading   the certificates onto the device.
   Invalid Root CA= 101:          Root CA incorrect due to expiry, invalid chain, or other issues verifying the server certificate.
   Invalid client authentication  Invalid client certificate or using a valid client identity but incorrectly associated with client certificate.
   =102:
Type Value Meaning
ConnectionFailed 0 Generic error message when certificate validation fails.
Certificate Not Found 100 Incorrect certificate specified when configuring the EAP-TLS network, or ReloadConfig() was not called after loading the certificates onto the device.
Invalid Root CA 101 Root CA incorrect due to expiry, invalid chain, or other issues verifying the server certificate.
Invalid client authentication 102 1) a client certificate that is not recognized by the server or that contains errors or 2) a valid client identity incorrectly associated with client certificate (for example, a known username with another user's password).
Unknown Client Id 103 The client identity was not recognized by the authentication server.

int32_t certDepth

The certificate's position in the certification chain. Meaningful only when error indicates AuthenticationFailed and certDepth is a non-negative (0 or positive) number.

CertStore_SubjectName certSubject

The certificate's subject. Meaningful only when error indicates AuthenticationFailed.