[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7ABATXATR7ND4K15WVJCB08":3,"skill-same:01M7ABATXATR7ND4K15WVJCB08":87},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":16,"sourceHtmlUrl":17,"categories":18,"keywords":19,"publishedAt":20,"linkOnly":21,"markdownContent":22,"markdownBody":23,"frontMatter":24,"refName":50,"commitSha":51,"skillDirectory":52,"forksCount":14,"repositoryHtmlUrl":53,"repositoryHomepageUrl":6,"ownerHtmlUrl":54,"ownerBlogUrl":6,"ownerDescription":55,"updatedAt":56,"install":57,"resources":70},"01M7ABATXATR7ND4K15WVJCB08","securing-remote-access-to-ot-environment",null,"Designs and configures secure remote access to OT\u002FICS environments for operators, engineers, and vendors: jump server architecture, multi-factor authentication, session recording, privileged access management, vendor access controls, and IEC 62443 \u002F NERC CIP-005 compliance. Use when designing OT remote access architecture or configuring a jump server with privileged access management.","NeelakshSaxena\u002FVayu","NeelakshSaxena","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F87892838?v=4","01M7A3B9YFS6F6N9DD1787DT86","Neelaksh Saxena","01M7A3B9ZKBT09MNMPX2XN69BY",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment\u002FLICENSE","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: securing-remote-access-to-ot-environment\ndescription: 'Designs and configures secure remote access to OT\u002FICS environments for\n  operators, engineers, and vendors: jump server architecture, multi-factor authentication,\n  session recording, privileged access management, vendor access controls, and IEC\n  62443 \u002F NERC CIP-005 compliance. Use when designing OT remote access architecture\n  or configuring a jump server with privileged access management.\n\n  '\ndomain: cybersecurity\nsubdomain: ot-ics-security\ntags:\n- ot-security\n- ics\n- scada\n- industrial-control\n- iec62443\n- remote-access\n- jump-server\n- mfa\nversion: 1.0.0\nauthor: mahipal\nlicense: Apache-2.0\nnist_csf:\n- PR.IR-01\n- DE.CM-01\n- ID.AM-05\n- GV.OC-02\nmitre_attack:\n- T1078\n- T1190\n- T1059\n- T0816\n- T0836\n---\n\n# Securing Remote Access to OT Environment\n\n## When to Use\n\n- When implementing or upgrading remote access architecture for OT environments\n- When onboarding vendors who require remote access to OT systems for support and maintenance\n- When implementing CIP-005-7 R2 requirements for remote access management including MFA\n- When replacing legacy direct VPN access to OT networks with a secure jump server architecture\n- When responding to an incident involving unauthorized remote access to industrial control systems\n\n**Do not use** for securing IT-only remote access without OT components, for configuring VPN for corporate workers (see general VPN guides), or for physical access control to OT facilities.\n\n## Prerequisites\n\n- DMZ infrastructure (Level 3.5) between corporate IT and OT networks\n- Jump server\u002Fbastion host platform (CyberArk, BeyondTrust, or hardened Windows\u002FLinux server)\n- Multi-factor authentication solution (Duo, RSA SecurID, YubiKey, smart cards)\n- Session recording capability for audit trail compliance\n- Firewall rules permitting remote access only through the DMZ intermediate system\n\n## Workflow\n\n### Step 1: Design Secure Remote Access Architecture\n\nImplement a defense-in-depth remote access architecture with an intermediate system in the DMZ that prevents any direct network connectivity between external users and OT systems.\n\n```yaml\n# OT Remote Access Architecture\n# Key principle: NO direct connection from external networks to OT systems\n\narchitecture:\n  external_access_point:\n    location: \"Internet-facing firewall\"\n    service: \"VPN gateway (IKEv2\u002FIPsec or SSL VPN)\"\n    authentication: \"Certificate + MFA (CIP-005-7 R2.4)\"\n    controls:\n      - \"Source IP allowlisting for vendor access\"\n      - \"Time-based access windows\"\n      - \"Bandwidth rate limiting\"\n\n  dmz_intermediate_system:\n    location: \"Level 3.5 DMZ\"\n    platform: \"CyberArk Privileged Access Security or hardened jump server\"\n    function: \"Session broker - terminates external connection, initiates new internal connection\"\n    controls:\n      - \"All sessions terminate at jump server (no pass-through)\"\n      - \"Session recording with keystroke logging\"\n      - \"Clipboard and file transfer restrictions\"\n      - \"Session timeout after 30 minutes inactivity\"\n      - \"Concurrent session limits per user\"\n\n  ot_internal_access:\n    location: \"Level 3 \u002F Level 2 OT network\"\n    method: \"Jump server initiates RDP\u002FSSH\u002FVNC to OT systems\"\n    controls:\n      - \"Firewall allows only jump server IP to reach OT\"\n      - \"Protocol restricted (RDP 3389, SSH 22, VNC 5900)\"\n      - \"Destination-specific per user role\"\n\n  vendor_access:\n    description: \"Third-party vendor remote access\"\n    additional_controls:\n      - \"Vendor account disabled by default; enabled on request\"\n      - \"Time-limited access windows (enable\u002Fdisable per session)\"\n      - \"OT operator must co-attend vendor sessions\"\n      - \"Real-time session monitoring by OT security\"\n      - \"No persistent credentials - one-time access tokens\"\n\n# Network flow:\n# User -> VPN -> Firewall -> DMZ Jump Server -> Internal FW -> OT System\n# (Two separate authenticated connections; no direct routing)\n```\n\n### Step 2: Configure Jump Server with Privileged Access Management\n\nDeploy and harden the jump server in the DMZ with session management, recording, and role-based access controls.\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"OT Remote Access Session Manager.\n\nManages authorized remote access sessions to OT environments\nincluding session creation, monitoring, recording, and termination.\nIntegrates with PAM solutions for credential vaulting.\n\"\"\"\n\nimport json\nimport hashlib\nimport sys\nfrom dataclasses import dataclass, field, asdict\nfrom datetime import datetime, timedelta\nfrom enum import Enum\n\n\nclass SessionState(str, Enum):\n    PENDING_APPROVAL = \"pending_approval\"\n    APPROVED = \"approved\"\n    ACTIVE = \"active\"\n    TERMINATED = \"terminated\"\n    EXPIRED = \"expired\"\n    DENIED = \"denied\"\n\n\nclass UserRole(str, Enum):\n    OT_OPERATOR = \"ot_operator\"\n    OT_ENGINEER = \"ot_engineer\"\n    VENDOR = \"vendor\"\n    SECURITY_ANALYST = \"security_analyst\"\n\n\n@dataclass\nclass RemoteAccessSession:\n    session_id: str\n    user_id: str\n    user_role: str\n    source_ip: str\n    target_system: str\n    target_ip: str\n    protocol: str\n    purpose: str\n    state: str = SessionState.PENDING_APPROVAL\n    mfa_verified: bool = False\n    approved_by: str = \"\"\n    created_at: str = \"\"\n    started_at: str = \"\"\n    ended_at: str = \"\"\n    max_duration_minutes: int = 120\n    recording_path: str = \"\"\n    actions_logged: list = field(default_factory=list)\n\n\nclass OTRemoteAccessManager:\n    \"\"\"Manages remote access sessions to OT environment.\"\"\"\n\n    def __init__(self):\n        self.sessions = {}\n        self.active_sessions = {}\n        self.access_policies = {}\n        self.audit_log = []\n\n    def define_access_policy(self, role, allowed_targets, protocols, max_duration):\n        \"\"\"Define access policy for a user role.\"\"\"\n        self.access_policies[role] = {\n            \"allowed_targets\": allowed_targets,\n            \"allowed_protocols\": protocols,\n            \"max_duration_minutes\": max_duration,\n            \"requires_co_attendance\": role == UserRole.VENDOR,\n            \"requires_approval\": role == UserRole.VENDOR,\n        }\n\n    def request_session(self, user_id, user_role, source_ip,\n                        target_system, target_ip, protocol, purpose):\n        \"\"\"Request a new remote access session.\"\"\"\n        # Generate unique session ID\n        session_id = hashlib.sha256(\n            f\"{user_id}{target_ip}{datetime.now().isoformat()}\".encode()\n        ).hexdigest()[:16]\n\n        # Check access policy\n        policy = self.access_policies.get(user_role)\n        if not policy:\n            return None, \"No access policy defined for role\"\n\n        if target_system not in policy[\"allowed_targets\"]:\n            self._audit(\"ACCESS_DENIED\", user_id, target_system,\n                       f\"Target not in allowed list for role {user_role}\")\n            return None, f\"Target {target_system} not authorized for role {user_role}\"\n\n        if protocol not in policy[\"allowed_protocols\"]:\n            self._audit(\"ACCESS_DENIED\", user_id, target_system,\n                       f\"Protocol {protocol} not allowed for role {user_role}\")\n            return None, f\"Protocol {protocol} not authorized\"\n\n        session = RemoteAccessSession(\n            session_id=session_id,\n            user_id=user_id,\n            user_role=user_role,\n            source_ip=source_ip,\n            target_system=target_system,\n            target_ip=target_ip,\n            protocol=protocol,\n            purpose=purpose,\n            max_duration_minutes=policy[\"max_duration_minutes\"],\n            created_at=datetime.now().isoformat(),\n        )\n\n        # Vendor sessions require approval\n        if policy.get(\"requires_approval\"):\n            session.state = SessionState.PENDING_APPROVAL\n        else:\n            session.state = SessionState.APPROVED\n\n        self.sessions[session_id] = session\n        self._audit(\"SESSION_REQUESTED\", user_id, target_system, purpose)\n\n        return session_id, \"Session created\"\n\n    def approve_session(self, session_id, approver_id):\n        \"\"\"Approve a pending vendor session.\"\"\"\n        session = self.sessions.get(session_id)\n        if not session:\n            return False, \"Session not found\"\n        if session.state != SessionState.PENDING_APPROVAL:\n            return False, \"Session not in pending approval state\"\n\n        session.state = SessionState.APPROVED\n        session.approved_by = approver_id\n        self._audit(\"SESSION_APPROVED\", approver_id, session.target_system,\n                    f\"Approved session {session_id} for {session.user_id}\")\n        return True, \"Session approved\"\n\n    def activate_session(self, session_id, mfa_token):\n        \"\"\"Activate an approved session after MFA verification.\"\"\"\n        session = self.sessions.get(session_id)\n        if not session or session.state != SessionState.APPROVED:\n            return False, \"Session not approved\"\n\n        # Verify MFA (simplified - real implementation calls MFA provider)\n        session.mfa_verified = True\n        session.state = SessionState.ACTIVE\n        session.started_at = datetime.now().isoformat()\n        session.recording_path = f\"\u002Frecordings\u002F{session_id}_{datetime.now().strftime('%Y%m%d')}.mp4\"\n\n        self.active_sessions[session_id] = session\n        self._audit(\"SESSION_ACTIVATED\", session.user_id, session.target_system,\n                    f\"MFA verified, recording to {session.recording_path}\")\n\n        return True, \"Session active\"\n\n    def terminate_session(self, session_id, reason=\"manual\"):\n        \"\"\"Terminate an active session.\"\"\"\n        session = self.active_sessions.pop(session_id, None)\n        if not session:\n            session = self.sessions.get(session_id)\n        if not session:\n            return False\n\n        session.state = SessionState.TERMINATED\n        session.ended_at = datetime.now().isoformat()\n        self._audit(\"SESSION_TERMINATED\", session.user_id, session.target_system, reason)\n        return True\n\n    def check_expired_sessions(self):\n        \"\"\"Terminate sessions that have exceeded their maximum duration.\"\"\"\n        now = datetime.now()\n        expired = []\n        for sid, session in list(self.active_sessions.items()):\n            started = datetime.fromisoformat(session.started_at)\n            if (now - started).total_seconds() > session.max_duration_minutes * 60:\n                self.terminate_session(sid, \"maximum_duration_exceeded\")\n                expired.append(sid)\n        return expired\n\n    def _audit(self, event_type, user_id, target, detail):\n        \"\"\"Write to audit log.\"\"\"\n        self.audit_log.append({\n            \"timestamp\": datetime.now().isoformat(),\n            \"event\": event_type,\n            \"user\": user_id,\n            \"target\": target,\n            \"detail\": detail,\n        })\n\n    def generate_report(self):\n        \"\"\"Generate remote access session report.\"\"\"\n        report = []\n        report.append(\"=\" * 70)\n        report.append(\"OT REMOTE ACCESS SESSION REPORT\")\n        report.append(f\"Date: {datetime.now().isoformat()}\")\n        report.append(\"=\" * 70)\n\n        # Session summary\n        total = len(self.sessions)\n        active = sum(1 for s in self.sessions.values() if s.state == SessionState.ACTIVE)\n        report.append(f\"\\nTotal Sessions: {total}\")\n        report.append(f\"Active Sessions: {active}\")\n\n        # Active sessions detail\n        if self.active_sessions:\n            report.append(\"\\nACTIVE SESSIONS:\")\n            for sid, s in self.active_sessions.items():\n                report.append(f\"  [{sid[:8]}] {s.user_id} ({s.user_role})\")\n                report.append(f\"    Target: {s.target_system} ({s.target_ip})\")\n                report.append(f\"    Started: {s.started_at}\")\n                report.append(f\"    MFA: {'Verified' if s.mfa_verified else 'NOT VERIFIED'}\")\n\n        return \"\\n\".join(report)\n\n\nif __name__ == \"__main__\":\n    manager = OTRemoteAccessManager()\n\n    # Define policies\n    manager.define_access_policy(\n        UserRole.OT_ENGINEER,\n        [\"HMI-01\", \"HMI-02\", \"EWS-01\", \"HISTORIAN-01\"],\n        [\"RDP\", \"SSH\"],\n        max_duration=240,\n    )\n    manager.define_access_policy(\n        UserRole.VENDOR,\n        [\"DCS-EWS-01\"],\n        [\"RDP\"],\n        max_duration=120,\n    )\n\n    # Request vendor session\n    sid, msg = manager.request_session(\n        \"vendor_honeywell_01\", UserRole.VENDOR,\n        \"203.0.113.50\", \"DCS-EWS-01\", \"10.30.1.20\",\n        \"RDP\", \"DCS firmware update per change request CR-2026-0045\")\n    print(f\"Session request: {msg} ({sid})\")\n\n    if sid:\n        manager.approve_session(sid, \"ot_manager_01\")\n        manager.activate_session(sid, \"123456\")\n        print(manager.generate_report())\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| Intermediate System | System in the DMZ that terminates external connections and brokers new connections to OT, preventing direct network access per CIP-005 |\n| Jump Server | Hardened bastion host in the DMZ used for remote access sessions to OT systems with session recording and access controls |\n| Session Recording | Capture of all remote access session activity (screen, keystrokes, commands) for security audit and incident investigation |\n| Privileged Access Management (PAM) | System for vaulting credentials, controlling access, and auditing privileged sessions to critical OT systems |\n| Co-Attendance | Requirement for an OT operator to monitor vendor remote access sessions in real time |\n| Time-Limited Access | Vendor accounts enabled only for specific maintenance windows and automatically disabled after the window closes |\n\n## Tools & Systems\n\n- **CyberArk Privileged Access Security**: Enterprise PAM with session management, credential vaulting, and recording for OT remote access\n- **BeyondTrust Privileged Remote Access**: Purpose-built remote access solution with session recording and granular access policies\n- **Claroty Secure Remote Access (SRA)**: OT-specific remote access solution with protocol-aware session controls\n- **Duo Security**: MFA provider supporting push notifications, hardware tokens, and biometrics for OT access verification\n\n## Output Format\n\n```\nOT Remote Access Security Report\n===================================\nActive Sessions: [N]\nPending Approval: [N]\nSessions Today: [N]\n\nMFA COMPLIANCE:\n  All sessions MFA verified: [Yes\u002FNo]\n  Sessions without MFA: [N]\n\nVENDOR ACCESS:\n  Active vendor sessions: [N]\n  Co-attended: [N]\n  Recorded: [N]\n```\n","# Securing Remote Access to OT Environment\n\n## When to Use\n\n- When implementing or upgrading remote access architecture for OT environments\n- When onboarding vendors who require remote access to OT systems for support and maintenance\n- When implementing CIP-005-7 R2 requirements for remote access management including MFA\n- When replacing legacy direct VPN access to OT networks with a secure jump server architecture\n- When responding to an incident involving unauthorized remote access to industrial control systems\n\n**Do not use** for securing IT-only remote access without OT components, for configuring VPN for corporate workers (see general VPN guides), or for physical access control to OT facilities.\n\n## Prerequisites\n\n- DMZ infrastructure (Level 3.5) between corporate IT and OT networks\n- Jump server\u002Fbastion host platform (CyberArk, BeyondTrust, or hardened Windows\u002FLinux server)\n- Multi-factor authentication solution (Duo, RSA SecurID, YubiKey, smart cards)\n- Session recording capability for audit trail compliance\n- Firewall rules permitting remote access only through the DMZ intermediate system\n\n## Workflow\n\n### Step 1: Design Secure Remote Access Architecture\n\nImplement a defense-in-depth remote access architecture with an intermediate system in the DMZ that prevents any direct network connectivity between external users and OT systems.\n\n```yaml\n# OT Remote Access Architecture\n# Key principle: NO direct connection from external networks to OT systems\n\narchitecture:\n  external_access_point:\n    location: \"Internet-facing firewall\"\n    service: \"VPN gateway (IKEv2\u002FIPsec or SSL VPN)\"\n    authentication: \"Certificate + MFA (CIP-005-7 R2.4)\"\n    controls:\n      - \"Source IP allowlisting for vendor access\"\n      - \"Time-based access windows\"\n      - \"Bandwidth rate limiting\"\n\n  dmz_intermediate_system:\n    location: \"Level 3.5 DMZ\"\n    platform: \"CyberArk Privileged Access Security or hardened jump server\"\n    function: \"Session broker - terminates external connection, initiates new internal connection\"\n    controls:\n      - \"All sessions terminate at jump server (no pass-through)\"\n      - \"Session recording with keystroke logging\"\n      - \"Clipboard and file transfer restrictions\"\n      - \"Session timeout after 30 minutes inactivity\"\n      - \"Concurrent session limits per user\"\n\n  ot_internal_access:\n    location: \"Level 3 \u002F Level 2 OT network\"\n    method: \"Jump server initiates RDP\u002FSSH\u002FVNC to OT systems\"\n    controls:\n      - \"Firewall allows only jump server IP to reach OT\"\n      - \"Protocol restricted (RDP 3389, SSH 22, VNC 5900)\"\n      - \"Destination-specific per user role\"\n\n  vendor_access:\n    description: \"Third-party vendor remote access\"\n    additional_controls:\n      - \"Vendor account disabled by default; enabled on request\"\n      - \"Time-limited access windows (enable\u002Fdisable per session)\"\n      - \"OT operator must co-attend vendor sessions\"\n      - \"Real-time session monitoring by OT security\"\n      - \"No persistent credentials - one-time access tokens\"\n\n# Network flow:\n# User -> VPN -> Firewall -> DMZ Jump Server -> Internal FW -> OT System\n# (Two separate authenticated connections; no direct routing)\n```\n\n### Step 2: Configure Jump Server with Privileged Access Management\n\nDeploy and harden the jump server in the DMZ with session management, recording, and role-based access controls.\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"OT Remote Access Session Manager.\n\nManages authorized remote access sessions to OT environments\nincluding session creation, monitoring, recording, and termination.\nIntegrates with PAM solutions for credential vaulting.\n\"\"\"\n\nimport json\nimport hashlib\nimport sys\nfrom dataclasses import dataclass, field, asdict\nfrom datetime import datetime, timedelta\nfrom enum import Enum\n\n\nclass SessionState(str, Enum):\n    PENDING_APPROVAL = \"pending_approval\"\n    APPROVED = \"approved\"\n    ACTIVE = \"active\"\n    TERMINATED = \"terminated\"\n    EXPIRED = \"expired\"\n    DENIED = \"denied\"\n\n\nclass UserRole(str, Enum):\n    OT_OPERATOR = \"ot_operator\"\n    OT_ENGINEER = \"ot_engineer\"\n    VENDOR = \"vendor\"\n    SECURITY_ANALYST = \"security_analyst\"\n\n\n@dataclass\nclass RemoteAccessSession:\n    session_id: str\n    user_id: str\n    user_role: str\n    source_ip: str\n    target_system: str\n    target_ip: str\n    protocol: str\n    purpose: str\n    state: str = SessionState.PENDING_APPROVAL\n    mfa_verified: bool = False\n    approved_by: str = \"\"\n    created_at: str = \"\"\n    started_at: str = \"\"\n    ended_at: str = \"\"\n    max_duration_minutes: int = 120\n    recording_path: str = \"\"\n    actions_logged: list = field(default_factory=list)\n\n\nclass OTRemoteAccessManager:\n    \"\"\"Manages remote access sessions to OT environment.\"\"\"\n\n    def __init__(self):\n        self.sessions = {}\n        self.active_sessions = {}\n        self.access_policies = {}\n        self.audit_log = []\n\n    def define_access_policy(self, role, allowed_targets, protocols, max_duration):\n        \"\"\"Define access policy for a user role.\"\"\"\n        self.access_policies[role] = {\n            \"allowed_targets\": allowed_targets,\n            \"allowed_protocols\": protocols,\n            \"max_duration_minutes\": max_duration,\n            \"requires_co_attendance\": role == UserRole.VENDOR,\n            \"requires_approval\": role == UserRole.VENDOR,\n        }\n\n    def request_session(self, user_id, user_role, source_ip,\n                        target_system, target_ip, protocol, purpose):\n        \"\"\"Request a new remote access session.\"\"\"\n        # Generate unique session ID\n        session_id = hashlib.sha256(\n            f\"{user_id}{target_ip}{datetime.now().isoformat()}\".encode()\n        ).hexdigest()[:16]\n\n        # Check access policy\n        policy = self.access_policies.get(user_role)\n        if not policy:\n            return None, \"No access policy defined for role\"\n\n        if target_system not in policy[\"allowed_targets\"]:\n            self._audit(\"ACCESS_DENIED\", user_id, target_system,\n                       f\"Target not in allowed list for role {user_role}\")\n            return None, f\"Target {target_system} not authorized for role {user_role}\"\n\n        if protocol not in policy[\"allowed_protocols\"]:\n            self._audit(\"ACCESS_DENIED\", user_id, target_system,\n                       f\"Protocol {protocol} not allowed for role {user_role}\")\n            return None, f\"Protocol {protocol} not authorized\"\n\n        session = RemoteAccessSession(\n            session_id=session_id,\n            user_id=user_id,\n            user_role=user_role,\n            source_ip=source_ip,\n            target_system=target_system,\n            target_ip=target_ip,\n            protocol=protocol,\n            purpose=purpose,\n            max_duration_minutes=policy[\"max_duration_minutes\"],\n            created_at=datetime.now().isoformat(),\n        )\n\n        # Vendor sessions require approval\n        if policy.get(\"requires_approval\"):\n            session.state = SessionState.PENDING_APPROVAL\n        else:\n            session.state = SessionState.APPROVED\n\n        self.sessions[session_id] = session\n        self._audit(\"SESSION_REQUESTED\", user_id, target_system, purpose)\n\n        return session_id, \"Session created\"\n\n    def approve_session(self, session_id, approver_id):\n        \"\"\"Approve a pending vendor session.\"\"\"\n        session = self.sessions.get(session_id)\n        if not session:\n            return False, \"Session not found\"\n        if session.state != SessionState.PENDING_APPROVAL:\n            return False, \"Session not in pending approval state\"\n\n        session.state = SessionState.APPROVED\n        session.approved_by = approver_id\n        self._audit(\"SESSION_APPROVED\", approver_id, session.target_system,\n                    f\"Approved session {session_id} for {session.user_id}\")\n        return True, \"Session approved\"\n\n    def activate_session(self, session_id, mfa_token):\n        \"\"\"Activate an approved session after MFA verification.\"\"\"\n        session = self.sessions.get(session_id)\n        if not session or session.state != SessionState.APPROVED:\n            return False, \"Session not approved\"\n\n        # Verify MFA (simplified - real implementation calls MFA provider)\n        session.mfa_verified = True\n        session.state = SessionState.ACTIVE\n        session.started_at = datetime.now().isoformat()\n        session.recording_path = f\"\u002Frecordings\u002F{session_id}_{datetime.now().strftime('%Y%m%d')}.mp4\"\n\n        self.active_sessions[session_id] = session\n        self._audit(\"SESSION_ACTIVATED\", session.user_id, session.target_system,\n                    f\"MFA verified, recording to {session.recording_path}\")\n\n        return True, \"Session active\"\n\n    def terminate_session(self, session_id, reason=\"manual\"):\n        \"\"\"Terminate an active session.\"\"\"\n        session = self.active_sessions.pop(session_id, None)\n        if not session:\n            session = self.sessions.get(session_id)\n        if not session:\n            return False\n\n        session.state = SessionState.TERMINATED\n        session.ended_at = datetime.now().isoformat()\n        self._audit(\"SESSION_TERMINATED\", session.user_id, session.target_system, reason)\n        return True\n\n    def check_expired_sessions(self):\n        \"\"\"Terminate sessions that have exceeded their maximum duration.\"\"\"\n        now = datetime.now()\n        expired = []\n        for sid, session in list(self.active_sessions.items()):\n            started = datetime.fromisoformat(session.started_at)\n            if (now - started).total_seconds() > session.max_duration_minutes * 60:\n                self.terminate_session(sid, \"maximum_duration_exceeded\")\n                expired.append(sid)\n        return expired\n\n    def _audit(self, event_type, user_id, target, detail):\n        \"\"\"Write to audit log.\"\"\"\n        self.audit_log.append({\n            \"timestamp\": datetime.now().isoformat(),\n            \"event\": event_type,\n            \"user\": user_id,\n            \"target\": target,\n            \"detail\": detail,\n        })\n\n    def generate_report(self):\n        \"\"\"Generate remote access session report.\"\"\"\n        report = []\n        report.append(\"=\" * 70)\n        report.append(\"OT REMOTE ACCESS SESSION REPORT\")\n        report.append(f\"Date: {datetime.now().isoformat()}\")\n        report.append(\"=\" * 70)\n\n        # Session summary\n        total = len(self.sessions)\n        active = sum(1 for s in self.sessions.values() if s.state == SessionState.ACTIVE)\n        report.append(f\"\\nTotal Sessions: {total}\")\n        report.append(f\"Active Sessions: {active}\")\n\n        # Active sessions detail\n        if self.active_sessions:\n            report.append(\"\\nACTIVE SESSIONS:\")\n            for sid, s in self.active_sessions.items():\n                report.append(f\"  [{sid[:8]}] {s.user_id} ({s.user_role})\")\n                report.append(f\"    Target: {s.target_system} ({s.target_ip})\")\n                report.append(f\"    Started: {s.started_at}\")\n                report.append(f\"    MFA: {'Verified' if s.mfa_verified else 'NOT VERIFIED'}\")\n\n        return \"\\n\".join(report)\n\n\nif __name__ == \"__main__\":\n    manager = OTRemoteAccessManager()\n\n    # Define policies\n    manager.define_access_policy(\n        UserRole.OT_ENGINEER,\n        [\"HMI-01\", \"HMI-02\", \"EWS-01\", \"HISTORIAN-01\"],\n        [\"RDP\", \"SSH\"],\n        max_duration=240,\n    )\n    manager.define_access_policy(\n        UserRole.VENDOR,\n        [\"DCS-EWS-01\"],\n        [\"RDP\"],\n        max_duration=120,\n    )\n\n    # Request vendor session\n    sid, msg = manager.request_session(\n        \"vendor_honeywell_01\", UserRole.VENDOR,\n        \"203.0.113.50\", \"DCS-EWS-01\", \"10.30.1.20\",\n        \"RDP\", \"DCS firmware update per change request CR-2026-0045\")\n    print(f\"Session request: {msg} ({sid})\")\n\n    if sid:\n        manager.approve_session(sid, \"ot_manager_01\")\n        manager.activate_session(sid, \"123456\")\n        print(manager.generate_report())\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|------------|\n| Intermediate System | System in the DMZ that terminates external connections and brokers new connections to OT, preventing direct network access per CIP-005 |\n| Jump Server | Hardened bastion host in the DMZ used for remote access sessions to OT systems with session recording and access controls |\n| Session Recording | Capture of all remote access session activity (screen, keystrokes, commands) for security audit and incident investigation |\n| Privileged Access Management (PAM) | System for vaulting credentials, controlling access, and auditing privileged sessions to critical OT systems |\n| Co-Attendance | Requirement for an OT operator to monitor vendor remote access sessions in real time |\n| Time-Limited Access | Vendor accounts enabled only for specific maintenance windows and automatically disabled after the window closes |\n\n## Tools & Systems\n\n- **CyberArk Privileged Access Security**: Enterprise PAM with session management, credential vaulting, and recording for OT remote access\n- **BeyondTrust Privileged Remote Access**: Purpose-built remote access solution with session recording and granular access policies\n- **Claroty Secure Remote Access (SRA)**: OT-specific remote access solution with protocol-aware session controls\n- **Duo Security**: MFA provider supporting push notifications, hardware tokens, and biometrics for OT access verification\n\n## Output Format\n\n```\nOT Remote Access Security Report\n===================================\nActive Sessions: [N]\nPending Approval: [N]\nSessions Today: [N]\n\nMFA COMPLIANCE:\n  All sessions MFA verified: [Yes\u002FNo]\n  Sessions without MFA: [N]\n\nVENDOR ACCESS:\n  Active vendor sessions: [N]\n  Co-attended: [N]\n  Recorded: [N]\n```\n",{"name":5,"tags":25,"author":34,"domain":35,"license":15,"version":36,"nist_csf":37,"subdomain":42,"description":43,"mitre_attack":44},[26,27,28,29,30,31,32,33],"ot-security","ics","scada","industrial-control","iec62443","remote-access","jump-server","mfa","mahipal","cybersecurity","1.0.0",[38,39,40,41],"PR.IR-01","DE.CM-01","ID.AM-05","GV.OC-02","ot-ics-security","Designs and configures secure remote access to OT\u002FICS environments for operators, engineers, and vendors: jump server architecture, multi-factor authentication, session recording, privileged access management, vendor access controls, and IEC 62443 \u002F NERC CIP-005 compliance. Use when designing OT remote access architecture or configuring a jump server with privileged access management.\n",[45,46,47,48,49],"T1078","T1190","T1059","T0816","T0836","main","7540bbccf0c1ded6156a467b02c95b61ad62413f",".agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena","Currently exploring the intersection of tech","2026-09-11 03:02:31",{"source":8,"skillName":5,"commands":58,"prompt":68,"zipAvailable":69},[59,62,65],{"tool":60,"command":61},"npx","npx skills add NeelakshSaxena\u002FVayu --skill securing-remote-access-to-ot-environment",{"tool":63,"command":64},"bunx","bunx skills add NeelakshSaxena\u002FVayu --skill securing-remote-access-to-ot-environment",{"tool":66,"command":67},"pnpm","pnpm dlx skills add NeelakshSaxena\u002FVayu --skill securing-remote-access-to-ot-environment","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment\u002FSKILL.md",true,[71,75,81],{"path":72,"resourceType":72,"resourceTypeDesc":73,"sizeBytes":74,"sourceHtmlUrl":16},"LICENSE","许可证",11255,{"path":76,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":79,"sourceHtmlUrl":80},"references\u002Fapi-reference.md","REFERENCE","参考文档",1737,"https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment\u002Freferences\u002Fapi-reference.md",{"path":82,"resourceType":83,"resourceTypeDesc":84,"sizeBytes":85,"sourceHtmlUrl":86},"scripts\u002Fagent.py","SCRIPT","脚本",7218,"https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fsecuring-remote-access-to-ot-environment\u002Fscripts\u002Fagent.py",[88,95,102,109,116,123],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":20},"01M7ACCCVNCFKMA9X6D15X6G98","runpodctl","Runpod CLI for managing GPU\u002FCPU workloads from the terminal — pods, serverless endpoints, templates, network volumes, Hub deploys, models, SSH, and file transfer (send\u002Freceive). Use for terminal\u002FCI\u002Fscripting, Hub browse\u002Fdeploy, SSH setup, `doctor`, or when the Runpod MCP tools are not connected. For structured tool calls in an MCP-enabled session, prefer runpod-mcp.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpodctl\u002FSKILL.md",[],[],{"skillNo":96,"name":97,"nameZh":6,"description":98,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":20},"01M7ACC63SRHEA5KMCHSMZK2TC","runpod","Start here for any Runpod task — running GPU\u002FCPU pods, deploying serverless endpoints, templates, network volumes, building images, or understanding how Runpod works. Routes to the right skill (runpod-mcp, runpodctl, flash, companion-clis, runpod-usage, runpod-templates, runpod-migrate) and indexes two dozen live-verified end-to-end examples (golden paths) — use it when the lane is unclear, and for any multi-step or provisioning task even when it is not.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod\u002FSKILL.md",[],[],{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":20},"01M7ACC0Q1C89N9BZBV91CTQTF","runpod-usage","How Runpod works and how to work it — pods vs serverless, GPU\u002FVRAM selection, storage, building a container, networking, plus the agentic pod development loop (provision → ssh-exec → set up → poll readiness) and on-pod install hygiene (uv\u002Fapt). Use to answer \"how does X work\", \"which GPU\", \"how do I build a container\", or \"how do I stand up a workload on a pod\". Guidance, not a tool — execute with runpodctl, runpod-mcp, or flash.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-usage\u002FSKILL.md",[],[],{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":20},"01M7ACBRPE345GF5GM5B8P8RRC","runpod-templates","Runpod's official prebuilt pod templates (ComfyUI, PyTorch, and others): what each image ships, which ports and paths it uses, how to pick one, how to pin a version, and what is missing on first boot. Use when a task says \"run \u003CX> on a pod\" and an official template already covers it, instead of building an image — and when a user needs help with or wants to fix something about a Runpod template they are already running (won't boot, can't reach the UI, missing models, wrong CUDA line, broken ComfyUI workflow metadata on imported workflows): start here and route onward. Deploy with runpodctl or runpod-mcp; end-to-end walkthroughs live in the runpod router's golden paths.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-templates\u002FSKILL.md",[],[],{"skillNo":117,"name":118,"nameZh":6,"description":119,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":120,"categories":121,"keywords":122,"publishedAt":20},"01M7ACBJATHKVX1TWES2F44GY8","runpod-migrate","Migrate a codebase from the Runpod GraphQL API or REST v1 to REST v2 — inventory which parts use which API version, rewrite the call sites, flag breaking changes, and verify. Use when someone asks to move to v2, asks what v2 would change, or asks which Runpod API their code is on. For managing infrastructure rather than migrating code, use runpod-mcp or runpodctl.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-migrate\u002FSKILL.md",[],[],{"skillNo":124,"name":125,"nameZh":6,"description":126,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":127,"categories":128,"keywords":129,"publishedAt":20},"01M7ACBC7GHVH6T9YEAPCG2AP8","runpod-mcp","Manage Runpod infrastructure — pods, serverless endpoints, jobs, templates, network volumes, container-registry auth, GPU\u002FCPU catalog, and billing — via the Runpod MCP server's structured tool calls. Use when the Runpod MCP tools (create-pod, list-endpoints, …) are connected in this session, or to connect them (hosted OAuth or local npx). Prefer this over runpodctl for plain infra CRUD when MCP is available; use runpodctl for the terminal, file transfer, or SSH setup.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-mcp\u002FSKILL.md",[],[]]