LoginSignup
0
0

More than 1 year has passed since last update.

JANOG51 NETCON Level4-3問題解説

Posted at

はじめに

2023年1月24日~26日(JANOG51の会期は1/25~1/27)に行われたJANOG51 NETCONで出題されたLevel4-3の問題解説です。

問題

image.png
これまでは、業務用のWiFi(SSID:J51-NETCON001)とゲストオープンアクセス用WiFi(SSID:J51-NETCON002)を運用していた。
ゲスト用のWiFiは、セキュリティの設定をしておらず、だれでも簡単に接続できるがその分危険性も高い。
そこで、事前共有キーを使った新しいゲスト用WiFi(SSID:J51-NETCON003)を運用することにした。
当社では、WLCを使って一括管理をしている。

スタッフ「うーん、新しいSSIDを設定したのですが、うまくつながりませんねー」
私「どうやって設定したの?」
スタッフ「既存のゲスト用J51-NETCON002をコピーしました」
私「今どんな状態?」
スタッフ「接続できないんです」
私「セキュリティの設定はWPAで事前共有キーはj51netconだね」
私「akmはpsk-sha256だよ」
私「セキュリティの設定とVLANの設定は問題ないか確認してみて」
私「設定が完了したら、実際に接続してみて10.0.0.2にpingが通るか確認してね」

SSID一覧

SSID 利用目的
J51-NETCON001 業務用(セキュリティあり)
J51-NETCON002 ゲスト用 OPEN
J51-NETCON003 ゲスト用(セキュリティあり)

機器のIPアドレス一覧

ホスト名 IP
J51-NETCON-EWC01 192.168.10.50
J51-ICX01 192.168.10.250
J51-ICX02 192.168.10.251
J51-AP1 192.168.10.101
J51-AP2 192.168.10.102
J51-AP3 192.168.10.103

VLAN一覧

VLAN ID 用途 ネットワーク
10 管理ネットワーク 192.168.10.0/24
2101 J51-NETCON001用 192.168.51.0/24
2102 J51-NETCON002用 172.17.1.0/24
2103 J51-NETCON003用 10.0.0.0/16

問題解説

まずは、無線のセキュリティ設定について。
SSID:J51-NETCON002の設定をコピーしたということで、セキュリティ設定がオープンアクセスのままになっています。

J51-EWC
 (config)# wlan J51-NETCON003 3 J51-NETCON003
 (config-wlan)# security wpa psk set-key ascii 0 j51netcon
 (config-wlan)# security wpa akm psk-sha256
 (config-wlan)# no shutdown

でWPAの事前共有キーの設定と暗号化アルゴリズムにpsk-sha256を使うよう設定を追加します。
問題の状態で、このwlanはshutdown状態になっているため、no shutdownを入れて活性化します。

また、割り当てられたポリシープロファイル(J51_WLANID_3)ですが、こちらもJ51-NETCON002用をコピーしたもので、よく見ると対応付けされたVLANがJ51-NETCON002のままになっています。

J51-EWC
 (config)# wireless profile policy J51_WLANID_3
 (config)# vlan 2303
 (config)# no shutdown

こちらも問題の状態でこのPolicy Profileがshutdown状態なので、no shutdownを入れて活性化します。
これで設定は完了です。

しばらくすると各APに設定が伝播し、接続できるようになります。
なお、L2スイッチ側の設定は問題ありません。

問題config
Current configuration : 12059 bytes
!
! Last configuration change at 14:29:53 JST Sun Jan 15 2023 by j51netcon
! NVRAM config last updated at 14:41:35 JST Sun Jan 15 2023 by j51netcon
!
version 17.9
!
hostname J51-NETCON-EWC01
!
boot-start-marker
boot-end-marker
!
!
aaa new-model
aaa local authentication default authorization default
!        
!
!
aaa common-criteria policy NETCONP
 min-length 4
 max-length 12
 char-changes 1
!
!
username j51netcon privilege 15 secret 9 $9$2l6K1kwD4/.E4.$s8ajPi2WF1q12JepwUTezEFzhutBOg1g/5j/Rjf251g
!
redundancy
 mode sso
!
!
!        
interface GigabitEthernet0
 mac-address 0000.5e00.0101
 ip dhcp client client-id GigabitEthernet0
 ip dhcp client broadcast-flag clear
 ip address 192.168.24.50 255.255.255.0
!
!
control-plane
!
banner exec ^C
########################################################################################################
#                                                                                                      #
#      Welcome to the Cisco Catalyst C9800-AP Embedded Wireless Controller command line interface      #
#                                                                                                      #
# Please see command reference guide for the complete list of supported commands for this release:     #
# https://www.cisco.com/c/en/us/td/docs/wireless/embedded_wireless_controller_configuration_guide.html #
#                                                                                                      #
########################################################################################################
^C
!
line con 0
 stopbits 1
line vty 0 4
 length 0
 transport input ssh
line vty 5 15
 transport input ssh
!
ntp server 192.168.24.51 prefer
!
!        
!
!
!
wireless aaa policy default-aaa-policy
wireless cts-sxp profile default-sxp-profile
wireless management interface GigabitEthernet0
wireless mesh ethernet-bridging allow-bdpu
wireless profile airtime-fairness default-atf-policy 0
wireless profile flex J51
 local-auth radius-server-group radgrp_J51
 native-vlan-id 10
 vlan-name VLAN2101
  vlan-id 2101
 vlan-name VLAN2102
  vlan-id 2102
 vlan-name VLAN2103
  vlan-id 2103
wireless profile flex default-flex-profile
 description "default flex profile"
wireless profile image-download default
 description "default image download profile"
 image-download-mode tftp
  tftp-image-path /download/C9800/
  tftp-image-server 192.168.24.10
wireless profile mesh J51-NETCON-MESH
 bridge-group name J51-NETC
 ccn
 ethernet-bridging
wireless profile mesh default-mesh-profile
 description "default mesh profile"
wireless profile radio default-radio-profile
 description "Preconfigured default radio profile"
wireless profile policy J51_WLANID_1
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON001
 vlan 2101
 no shutdown
wireless profile policy J51_WLANID_2
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON002
 vlan 2102
 no shutdown
wireless profile policy J51_WLANID_3
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON003
 vlan 2102
 shutdown
wireless profile policy default-policy-profile
 no central association
 no central dhcp
 no central switching
 description "default policy profile"
 dhcp-tlv-caching
 http-tlv-caching
 ipv4 flow monitor default-flow-monitor input
 ipv4 flow monitor default-flow-monitor output
 no shutdown
wireless tag site default-site-tag
 ap-profile J51
 description "default site tag"
 flex-profile J51
 no local-site
wireless tag policy J51-NETCON-WLAN
 wlan J51-NETCON001 policy J51_WLANID_1
 wlan J51-NETCON002 policy J51_WLANID_2
 wlan J51-NETCON003 policy J51_WLANID_3
wireless tag policy default-policy-tag
 description "default policy-tag"
 wlan J51-NETCON001 policy J51_WLANID_1
 wlan J51-NETCON002 policy J51_WLANID_2
wireless tag rf default-rf-tag
 24ghz-rf-policy Typical_Client_Density_rf_24gh
 5ghz-rf-policy Typical_Client_Density_rf_5gh
 description "default RF tag"
wireless country J4
wlan J51-NETCON001 1 J51-NETCON001
 no shutdown
wlan J51-NETCON002 2 J51-NETCON002
 security ft over-the-ds
 no security wpa
 no security wpa wpa2
 no security wpa wpa2 ciphers aes
 no security wpa akm dot1x
 no shutdown
wlan J51-NETCON003 3 J51-NETCON003
 dot11ax target-waketime
 dot11ax twt-broadcast-support
 no security ft adaptive
 no security wpa psk set-key ascii 0 j51netcon
 no security wpa akm dot1x
 no security wpa akm psk-sha256
 shutdown
ap profile J51
 antenna monitoring
 country J4
 no ip dhcp fallback
 lag
 ntp ip 192.168.24.51
 timezone use-controller
netconf-yang
end

(一部端折っています)

解答config
Current configuration : 12059 bytes
!
! Last configuration change at 14:29:53 JST Sun Jan 15 2023 by j51netcon
! NVRAM config last updated at 14:41:35 JST Sun Jan 15 2023 by j51netcon
!
version 17.9
!
hostname J51-NETCON-EWC01
!
boot-start-marker
boot-end-marker
!
!
aaa new-model
aaa local authentication default authorization default
!        
!
!
!
aaa common-criteria policy NETCONP
 min-length 4
 max-length 12
 char-changes 1
!
!
aaa session-id common
clock timezone JST 9 0
no fips authorization-key
!
!
!
!
!
service-template DEFAULT_LINKSEC_POLICY_MUST_SECURE
 linksec policy must-secure
service-template DEFAULT_LINKSEC_POLICY_SHOULD_SECURE
 linksec policy should-secure
service-template DEFAULT_CRITICAL_VOICE_TEMPLATE
 voice vlan
service-template DEFAULT_CRITICAL_DATA_TEMPLATE
service-template webauth-global-inactive
 inactivity-timer 3600
memory free low-watermark processor 12957
!
username j51netcon privilege 15 secret 9 $9$2l6K1kwD4/.E4.$s8ajPi2WF1q12JepwUTezEFzhutBOg1g/5j/Rjf251g
!
redundancy
 mode sso
!
!
!
!
!
interface GigabitEthernet0
 mac-address 0000.5e00.0101
 ip dhcp client client-id GigabitEthernet0
 ip dhcp client broadcast-flag clear
 ip address 192.168.24.50 255.255.255.0
!        
!
!
!
radius-server attribute wireless accounting mac-delimiter colon
radius-server attribute wireless authentication mac-delimiter colon
radius-server attribute wireless authentication call-station-id ap-macaddress
!
!
control-plane
!
banner exec ^C
########################################################################################################
#                                                                                                      #
#      Welcome to the Cisco Catalyst C9800-AP Embedded Wireless Controller command line interface      #
#                                                                                                      #
# Please see command reference guide for the complete list of supported commands for this release:     #
# https://www.cisco.com/c/en/us/td/docs/wireless/embedded_wireless_controller_configuration_guide.html #
#                                                                                                      #
########################################################################################################
^C
!
line con 0
 stopbits 1
line vty 0 4
 length 0
 transport input ssh
line vty 5 15
 transport input ssh
!
ntp server 192.168.24.51 prefer
!
!        
!
!
!
wireless aaa policy default-aaa-policy
wireless cts-sxp profile default-sxp-profile
wireless management interface GigabitEthernet0
wireless mesh ethernet-bridging allow-bdpu
wireless profile airtime-fairness default-atf-policy 0
wireless profile flex J51
 local-auth radius-server-group radgrp_J51
 native-vlan-id 10
 vlan-name VLAN2101
  vlan-id 2101
 vlan-name VLAN2102
  vlan-id 2102
 vlan-name VLAN2103
  vlan-id 2103
wireless profile flex default-flex-profile
 description "default flex profile"
wireless profile image-download default
 description "default image download profile"
 image-download-mode tftp
  tftp-image-path /download/C9800/
  tftp-image-server 192.168.24.10
wireless profile mesh J51-NETCON-MESH
 bridge-group name J51-NETC
 ccn
 ethernet-bridging
wireless profile mesh default-mesh-profile
 description "default mesh profile"
wireless profile radio default-radio-profile
 description "Preconfigured default radio profile"
wireless profile policy J51_WLANID_1
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON001
 vlan 2101
 no shutdown
wireless profile policy J51_WLANID_2
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON002
 vlan 2102
 no shutdown
wireless profile policy J51_WLANID_3
 no central association
 no central dhcp
 no central switching
 description J51_J51-NETCON003
 vlan 2103
 no shutdown
wireless profile policy default-policy-profile
 no central association
 no central dhcp
 no central switching
 description "default policy profile"
 dhcp-tlv-caching
 http-tlv-caching
 ipv4 flow monitor default-flow-monitor input
 ipv4 flow monitor default-flow-monitor output
 no shutdown
wireless tag site default-site-tag
 ap-profile J51
 description "default site tag"
 flex-profile J51
 no local-site
wireless tag policy J51-NETCON-WLAN
 wlan J51-NETCON001 policy J51_WLANID_1
 wlan J51-NETCON002 policy J51_WLANID_2
 wlan J51-NETCON003 policy J51_WLANID_3
wireless tag policy default-policy-tag
 description "default policy-tag"
 wlan J51-NETCON001 policy J51_WLANID_1
 wlan J51-NETCON002 policy J51_WLANID_2
wireless tag rf default-rf-tag
 24ghz-rf-policy Typical_Client_Density_rf_24gh
 5ghz-rf-policy Typical_Client_Density_rf_5gh
 description "default RF tag"
wireless country J4
wlan J51-NETCON001 1 J51-NETCON001
 no shutdown
wlan J51-NETCON002 2 J51-NETCON002
 security ft over-the-ds
 no security wpa
 no security wpa wpa2
 no security wpa wpa2 ciphers aes
 no security wpa akm dot1x
 no shutdown
wlan J51-NETCON003 3 J51-NETCON003
 dot11ax target-waketime
 dot11ax twt-broadcast-support
 no security ft adaptive
 security wpa psk set-key ascii 0 j51netcon
 no security wpa akm dot1x
 security wpa akm psk-sha256
 no shutdown
ap tri-radio
ap auth-list method-list AP-AUTH
ap tag-source-priority 2 source filter
ap tag-source-priority 3 source ap
ap profile J51
 antenna monitoring
 country J4
 no ip dhcp fallback
 lag
 ntp ip 192.168.24.51
 timezone use-controller

end

(一部端折っています)

まとめ

今回はEWC(Embeded Wireless Controler)を使った問題でした。
中身は単純で、

  • Profile Policyに設定していあるVLANが間違ってる
  • WPAの設定ができていない

の2点でした。WirelessContorolerの設定をCLIでやる人はあんまりいません。
実は今回もWebUIがあるので、そっちでやると簡単に設定できます。
ただ、Ansibleなどで運用自動化している方にとっては、CLIの方が都合いいかもということでCLI限定にしました。
はまりどころとしては、Policyもwlanもshutdownされてるところですね。これらは設定変更時にshutdownしないと設定変更できません。

C9800コントローラに比べてEWCでは一部機能に差があるようです。
(まぁ、CPUもメモリもC9800とC9115AXでは違うのでその辺が問題なのでしょうか)

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0