ホーム › NetworkManagement.WindowsFilteringPlatform › IKEEXT_KEYMODULE_STATISTICS0
IKEEXT_KEYMODULE_STATISTICS0
構造体サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。
フィールド
| フィールド | 型 | サイズ | x64 | x86 | 説明 |
|---|---|---|---|---|---|
| v4Statistics | IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 | 72 | +0 | +0 | IPv4に関する鍵モジュール統計。 |
| v6Statistics | IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 | 72 | +72 | +72 | IPv6に関する鍵モジュール統計。 |
| errorFrequencyTable | DWORD | 388 | +144 | +144 | エラー種別ごとの発生頻度を格納する配列。 |
| mainModeNegotiationTime | DWORD | 4 | +532 | +532 | メインモードネゴシエーションの所要時間(ミリ秒)。 |
| quickModeNegotiationTime | DWORD | 4 | +536 | +536 | クイックモードネゴシエーションの所要時間(ミリ秒)。 |
| extendedModeNegotiationTime | DWORD | 4 | +540 | +540 | 拡張モードネゴシエーションの所要時間(ミリ秒)。 |
各言語での定義
#include <windows.h>
// IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 (x64 72 / x86 72 バイト)
typedef struct IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 {
DWORD currentActiveMainModes;
DWORD totalMainModesStarted;
DWORD totalSuccessfulMainModes;
DWORD totalFailedMainModes;
DWORD totalResponderMainModes;
DWORD currentNewResponderMainModes;
DWORD currentActiveQuickModes;
DWORD totalQuickModesStarted;
DWORD totalSuccessfulQuickModes;
DWORD totalFailedQuickModes;
DWORD totalAcquires;
DWORD totalReinitAcquires;
DWORD currentActiveExtendedModes;
DWORD totalExtendedModesStarted;
DWORD totalSuccessfulExtendedModes;
DWORD totalFailedExtendedModes;
DWORD totalImpersonationExtendedModes;
DWORD totalImpersonationMainModes;
} IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0;
// IKEEXT_KEYMODULE_STATISTICS0 (x64 544 / x86 544 バイト)
typedef struct IKEEXT_KEYMODULE_STATISTICS0 {
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v4Statistics;
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v6Statistics;
DWORD errorFrequencyTable[97];
DWORD mainModeNegotiationTime;
DWORD quickModeNegotiationTime;
DWORD extendedModeNegotiationTime;
} IKEEXT_KEYMODULE_STATISTICS0;using System;
using System.Runtime.InteropServices;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
{
public uint currentActiveMainModes;
public uint totalMainModesStarted;
public uint totalSuccessfulMainModes;
public uint totalFailedMainModes;
public uint totalResponderMainModes;
public uint currentNewResponderMainModes;
public uint currentActiveQuickModes;
public uint totalQuickModesStarted;
public uint totalSuccessfulQuickModes;
public uint totalFailedQuickModes;
public uint totalAcquires;
public uint totalReinitAcquires;
public uint currentActiveExtendedModes;
public uint totalExtendedModesStarted;
public uint totalSuccessfulExtendedModes;
public uint totalFailedExtendedModes;
public uint totalImpersonationExtendedModes;
public uint totalImpersonationMainModes;
}
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct IKEEXT_KEYMODULE_STATISTICS0
{
public IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v4Statistics;
public IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v6Statistics;
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 97)] public uint[] errorFrequencyTable;
public uint mainModeNegotiationTime;
public uint quickModeNegotiationTime;
public uint extendedModeNegotiationTime;
}Imports System.Runtime.InteropServices
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
Public currentActiveMainModes As UInteger
Public totalMainModesStarted As UInteger
Public totalSuccessfulMainModes As UInteger
Public totalFailedMainModes As UInteger
Public totalResponderMainModes As UInteger
Public currentNewResponderMainModes As UInteger
Public currentActiveQuickModes As UInteger
Public totalQuickModesStarted As UInteger
Public totalSuccessfulQuickModes As UInteger
Public totalFailedQuickModes As UInteger
Public totalAcquires As UInteger
Public totalReinitAcquires As UInteger
Public currentActiveExtendedModes As UInteger
Public totalExtendedModesStarted As UInteger
Public totalSuccessfulExtendedModes As UInteger
Public totalFailedExtendedModes As UInteger
Public totalImpersonationExtendedModes As UInteger
Public totalImpersonationMainModes As UInteger
End Structure
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure IKEEXT_KEYMODULE_STATISTICS0
Public v4Statistics As IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
Public v6Statistics As IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
<MarshalAs(UnmanagedType.ByValArray, SizeConst:=97)> Public errorFrequencyTable() As UInteger
Public mainModeNegotiationTime As UInteger
Public quickModeNegotiationTime As UInteger
Public extendedModeNegotiationTime As UInteger
End Structureimport ctypes
from ctypes import wintypes
class IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0(ctypes.Structure):
_fields_ = [
("currentActiveMainModes", wintypes.DWORD),
("totalMainModesStarted", wintypes.DWORD),
("totalSuccessfulMainModes", wintypes.DWORD),
("totalFailedMainModes", wintypes.DWORD),
("totalResponderMainModes", wintypes.DWORD),
("currentNewResponderMainModes", wintypes.DWORD),
("currentActiveQuickModes", wintypes.DWORD),
("totalQuickModesStarted", wintypes.DWORD),
("totalSuccessfulQuickModes", wintypes.DWORD),
("totalFailedQuickModes", wintypes.DWORD),
("totalAcquires", wintypes.DWORD),
("totalReinitAcquires", wintypes.DWORD),
("currentActiveExtendedModes", wintypes.DWORD),
("totalExtendedModesStarted", wintypes.DWORD),
("totalSuccessfulExtendedModes", wintypes.DWORD),
("totalFailedExtendedModes", wintypes.DWORD),
("totalImpersonationExtendedModes", wintypes.DWORD),
("totalImpersonationMainModes", wintypes.DWORD),
]
class IKEEXT_KEYMODULE_STATISTICS0(ctypes.Structure):
_fields_ = [
("v4Statistics", IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0),
("v6Statistics", IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0),
("errorFrequencyTable", wintypes.DWORD * 97),
("mainModeNegotiationTime", wintypes.DWORD),
("quickModeNegotiationTime", wintypes.DWORD),
("extendedModeNegotiationTime", wintypes.DWORD),
]#[repr(C)]
pub struct IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 {
pub currentActiveMainModes: u32,
pub totalMainModesStarted: u32,
pub totalSuccessfulMainModes: u32,
pub totalFailedMainModes: u32,
pub totalResponderMainModes: u32,
pub currentNewResponderMainModes: u32,
pub currentActiveQuickModes: u32,
pub totalQuickModesStarted: u32,
pub totalSuccessfulQuickModes: u32,
pub totalFailedQuickModes: u32,
pub totalAcquires: u32,
pub totalReinitAcquires: u32,
pub currentActiveExtendedModes: u32,
pub totalExtendedModesStarted: u32,
pub totalSuccessfulExtendedModes: u32,
pub totalFailedExtendedModes: u32,
pub totalImpersonationExtendedModes: u32,
pub totalImpersonationMainModes: u32,
}
#[repr(C)]
pub struct IKEEXT_KEYMODULE_STATISTICS0 {
pub v4Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0,
pub v6Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0,
pub errorFrequencyTable: [u32; 97],
pub mainModeNegotiationTime: u32,
pub quickModeNegotiationTime: u32,
pub extendedModeNegotiationTime: u32,
}import "golang.org/x/sys/windows"
type IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 struct {
currentActiveMainModes uint32
totalMainModesStarted uint32
totalSuccessfulMainModes uint32
totalFailedMainModes uint32
totalResponderMainModes uint32
currentNewResponderMainModes uint32
currentActiveQuickModes uint32
totalQuickModesStarted uint32
totalSuccessfulQuickModes uint32
totalFailedQuickModes uint32
totalAcquires uint32
totalReinitAcquires uint32
currentActiveExtendedModes uint32
totalExtendedModesStarted uint32
totalSuccessfulExtendedModes uint32
totalFailedExtendedModes uint32
totalImpersonationExtendedModes uint32
totalImpersonationMainModes uint32
}
type IKEEXT_KEYMODULE_STATISTICS0 struct {
v4Statistics IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
v6Statistics IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
errorFrequencyTable [97]uint32
mainModeNegotiationTime uint32
quickModeNegotiationTime uint32
extendedModeNegotiationTime uint32
}type
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 = record
currentActiveMainModes: DWORD;
totalMainModesStarted: DWORD;
totalSuccessfulMainModes: DWORD;
totalFailedMainModes: DWORD;
totalResponderMainModes: DWORD;
currentNewResponderMainModes: DWORD;
currentActiveQuickModes: DWORD;
totalQuickModesStarted: DWORD;
totalSuccessfulQuickModes: DWORD;
totalFailedQuickModes: DWORD;
totalAcquires: DWORD;
totalReinitAcquires: DWORD;
currentActiveExtendedModes: DWORD;
totalExtendedModesStarted: DWORD;
totalSuccessfulExtendedModes: DWORD;
totalFailedExtendedModes: DWORD;
totalImpersonationExtendedModes: DWORD;
totalImpersonationMainModes: DWORD;
end;
IKEEXT_KEYMODULE_STATISTICS0 = record
v4Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0;
v6Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0;
errorFrequencyTable: array[0..96] of DWORD;
mainModeNegotiationTime: DWORD;
quickModeNegotiationTime: DWORD;
extendedModeNegotiationTime: DWORD;
end;const IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 = extern struct {
currentActiveMainModes: u32,
totalMainModesStarted: u32,
totalSuccessfulMainModes: u32,
totalFailedMainModes: u32,
totalResponderMainModes: u32,
currentNewResponderMainModes: u32,
currentActiveQuickModes: u32,
totalQuickModesStarted: u32,
totalSuccessfulQuickModes: u32,
totalFailedQuickModes: u32,
totalAcquires: u32,
totalReinitAcquires: u32,
currentActiveExtendedModes: u32,
totalExtendedModesStarted: u32,
totalSuccessfulExtendedModes: u32,
totalFailedExtendedModes: u32,
totalImpersonationExtendedModes: u32,
totalImpersonationMainModes: u32,
};
const IKEEXT_KEYMODULE_STATISTICS0 = extern struct {
v4Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0,
v6Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0,
errorFrequencyTable: [97]u32,
mainModeNegotiationTime: u32,
quickModeNegotiationTime: u32,
extendedModeNegotiationTime: u32,
};type
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 {.bycopy.} = object
currentActiveMainModes: uint32
totalMainModesStarted: uint32
totalSuccessfulMainModes: uint32
totalFailedMainModes: uint32
totalResponderMainModes: uint32
currentNewResponderMainModes: uint32
currentActiveQuickModes: uint32
totalQuickModesStarted: uint32
totalSuccessfulQuickModes: uint32
totalFailedQuickModes: uint32
totalAcquires: uint32
totalReinitAcquires: uint32
currentActiveExtendedModes: uint32
totalExtendedModesStarted: uint32
totalSuccessfulExtendedModes: uint32
totalFailedExtendedModes: uint32
totalImpersonationExtendedModes: uint32
totalImpersonationMainModes: uint32
IKEEXT_KEYMODULE_STATISTICS0 {.bycopy.} = object
v4Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
v6Statistics: IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
errorFrequencyTable: array[97, uint32]
mainModeNegotiationTime: uint32
quickModeNegotiationTime: uint32
extendedModeNegotiationTime: uint32struct IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
{
uint currentActiveMainModes;
uint totalMainModesStarted;
uint totalSuccessfulMainModes;
uint totalFailedMainModes;
uint totalResponderMainModes;
uint currentNewResponderMainModes;
uint currentActiveQuickModes;
uint totalQuickModesStarted;
uint totalSuccessfulQuickModes;
uint totalFailedQuickModes;
uint totalAcquires;
uint totalReinitAcquires;
uint currentActiveExtendedModes;
uint totalExtendedModesStarted;
uint totalSuccessfulExtendedModes;
uint totalFailedExtendedModes;
uint totalImpersonationExtendedModes;
uint totalImpersonationMainModes;
}
struct IKEEXT_KEYMODULE_STATISTICS0
{
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v4Statistics;
IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v6Statistics;
uint[97] errorFrequencyTable;
uint mainModeNegotiationTime;
uint quickModeNegotiationTime;
uint extendedModeNegotiationTime;
}HSP用 定義
HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。
; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; IKEEXT_KEYMODULE_STATISTICS0 サイズ: 544 バイト(x64)
dim st, 136 ; 4byte整数×136(構造体サイズ 544 / 4 切り上げ)
; v4Statistics : IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 (+0, 72byte) varptr(st)+0 を基点に操作(72byte:入れ子/配列)
; v6Statistics : IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 (+72, 72byte) varptr(st)+72 を基点に操作(72byte:入れ子/配列)
; errorFrequencyTable : DWORD (+144, 388byte) varptr(st)+144 を基点に操作(388byte:入れ子/配列)
; mainModeNegotiationTime : DWORD (+532, 4byte) st.133 = 値 / 値 = st.133 (lpoke/lpeek も可)
; quickModeNegotiationTime : DWORD (+536, 4byte) st.134 = 値 / 値 = st.134 (lpoke/lpeek も可)
; extendedModeNegotiationTime : DWORD (+540, 4byte) st.135 = 値 / 値 = st.135 (lpoke/lpeek も可)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0
#field int currentActiveMainModes
#field int totalMainModesStarted
#field int totalSuccessfulMainModes
#field int totalFailedMainModes
#field int totalResponderMainModes
#field int currentNewResponderMainModes
#field int currentActiveQuickModes
#field int totalQuickModesStarted
#field int totalSuccessfulQuickModes
#field int totalFailedQuickModes
#field int totalAcquires
#field int totalReinitAcquires
#field int currentActiveExtendedModes
#field int totalExtendedModesStarted
#field int totalSuccessfulExtendedModes
#field int totalFailedExtendedModes
#field int totalImpersonationExtendedModes
#field int totalImpersonationMainModes
#endstruct
#defstruct global IKEEXT_KEYMODULE_STATISTICS0
#field IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v4Statistics
#field IKEEXT_IP_VERSION_SPECIFIC_KEYMODULE_STATISTICS0 v6Statistics
#field int errorFrequencyTable 97
#field int mainModeNegotiationTime
#field int quickModeNegotiationTime
#field int extendedModeNegotiationTime
#endstruct
stdim st, IKEEXT_KEYMODULE_STATISTICS0 ; NSTRUCT 変数を確保
st->mainModeNegotiationTime = 100
mes "mainModeNegotiationTime=" + st->mainModeNegotiationTime