先日、デプロイしたVyOS 1.2.9 LTSを利用してAWSとの間で動的ルーティングのVPNを試してみました。動的ルーティング構成では、VTIインターフェイスとBGPを利用します。なお、長時間の通信試験はしていません。利用した環境は、以下の通りです。
<利用した環境>
- VMware Workstation Player 17
- Windows11 Home
- VMware v1.2.9 LTS
- AWS 東京リージョン
<利用した構成図>
先日、デプロイしたVyOS 1.2.9 LTSを利用してAWSとの間で動的ルーティングのVPNを試してみました。動的ルーティング構成では、VTIインターフェイスとBGPを利用します。なお、長時間の通信試験はしていません。利用した環境は、以下の通りです。
<利用した環境>
<利用した構成図>
vyos@vyos:~$ show configuration commands set firewall all-ping 'enable' set firewall broadcast-ping 'disable' set firewall config-trap 'disable' set firewall ipv6-receive-redirects 'disable' set firewall ipv6-src-route 'disable' set firewall ip-src-route 'disable' set firewall log-martians 'enable' set firewall options interface vti0 adjust-mss '1394' set firewall receive-redirects 'disable' set firewall send-redirects 'enable' set firewall source-validation 'disable' set firewall syn-cookies 'enable' set firewall twa-hazards-protection 'disable' set interfaces ethernet eth0 address 'dhcp' set interfaces ethernet eth0 duplex 'auto' set interfaces ethernet eth0 hw-id '00:0c:29:f3:72:11' set interfaces ethernet eth0 smp-affinity 'auto' set interfaces ethernet eth0 speed 'auto' set interfaces ethernet eth1 address '192.168.1.1/24' set interfaces ethernet eth1 duplex 'auto' set interfaces ethernet eth1 hw-id '00:0c:29:f3:72:1b' set interfaces ethernet eth1 smp-affinity 'auto' set interfaces ethernet eth1 speed 'auto' set interfaces vti vti0 address '169.254.204.246/30' set interfaces vti vti0 mtu '1436' set nat source rule 1 outbound-interface 'eth0' set nat source rule 1 translation address 'masquerade' set protocols bgp 65000 address-family ipv4-unicast network 192.168.1.0/24 set protocols bgp 65000 neighbor 169.254.204.245 remote-as '64512' set protocols bgp 65000 neighbor 169.254.204.245 timers holdtime '30' set protocols bgp 65000 neighbor 169.254.204.245 timers keepalive '10' set protocols static interface-route 169.254.204.244/30 next-hop-interface vti0 set service ssh port '22' set system config-management commit-revisions '100' set system console device ttyS0 speed '9600' set system host-name 'vyos' set system login user vyos authentication encrypted-password '[vyos-password]' set system login user vyos authentication plaintext-password '' set system login user vyos level 'admin' set system ntp server 133.243.238.243 set system syslog global facility all level 'notice' set system syslog global facility protocols level 'debug' set system time-zone 'Asia/Tokyo' set vpn ipsec esp-group esp-grp-01 compression 'disable' set vpn ipsec esp-group esp-grp-01 lifetime '3600' set vpn ipsec esp-group esp-grp-01 mode 'tunnel' set vpn ipsec esp-group esp-grp-01 pfs 'dh-group21' set vpn ipsec esp-group esp-grp-01 proposal 1 encryption 'aes256' set vpn ipsec esp-group esp-grp-01 proposal 1 hash 'sha256' set vpn ipsec ike-group ike-grp-01 close-action 'none' set vpn ipsec ike-group ike-grp-01 dead-peer-detection action 'restart' set vpn ipsec ike-group ike-grp-01 dead-peer-detection interval '10' set vpn ipsec ike-group ike-grp-01 dead-peer-detection timeout '120' set vpn ipsec ike-group ike-grp-01 ikev2-reauth 'no' set vpn ipsec ike-group ike-grp-01 key-exchange 'ikev2' set vpn ipsec ike-group ike-grp-01 lifetime '28800' set vpn ipsec ike-group ike-grp-01 proposal 1 dh-group '21' set vpn ipsec ike-group ike-grp-01 proposal 1 encryption 'aes256' set vpn ipsec ike-group ike-grp-01 proposal 1 hash 'sha256' set vpn ipsec ipsec-interfaces interface 'eth0' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] authentication mode 'pre-shared-secret' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] authentication pre-shared-secret '[pre-shared key1]' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] connection-type 'initiate' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] default-esp-group 'esp-grp-01' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] description 'AWS-VPC-01' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] ike-group 'ike-grp-01' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] ikev2-reauth 'inherit' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] local-address '192.168.115.130' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] vti bind 'vti0' set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] vti esp-group 'esp-grp-01' vyos@vyos:~$
vyos@vyos:~$ show vpn ike sa Peer ID / IP Local ID / IP ------------ ------------- [AWS-VirtualPrivateGateway-IP1] 192.168.115.130 Description: AWS-VPC-01 State IKEVer Encrypt Hash D-H Group NAT-T A-Time L-Time ----- ------ ------- ---- --------- ----- ------ ------ up IKEv2 aes256 sha256_128 21(ECP_521) no 7200 28800 vyos@vyos:~$ show vpn ipsec sa Connection State Up Bytes In/Out Remote address Remote ID Proposal ----------------------------- ------- ----------- -------------- ---------------- ----------- ------------------------------------------------------- peer-[AWS-VirtualPrivateGateway-IP1]-tunnel-vti up 110 minutes 11K/16K [AWS-VirtualPrivateGateway-IP1] N/A AES_CBC_256/HMAC_SHA2_256_128/PRF_HMAC_SHA2_256/ECP_521 vyos@vyos:~$
vyos@vyos:~$ show ip bgp BGP table version is 2, local router ID is 192.168.115.130, vrf id 0 Default local pref 100, local AS 65000 Status codes: s suppressed, d damped, h history, * valid, > best, = multipath, i internal, r RIB-failure, S Stale, R Removed Nexthop codes: @NNN nexthop's vrf id, < announce-nh-self Origin codes: i - IGP, e - EGP, ? - incomplete Network Next Hop Metric LocPrf Weight Path *> 172.31.0.0/16 169.254.204.245 100 0 64512 i *> 192.168.1.0/24 0.0.0.0 0 32768 i Displayed 2 routes and 2 total paths vyos@vyos:~$ show ip bgp neighbors BGP neighbor is 169.254.204.245, remote AS 64512, local AS 65000, external link BGP version 4, remote router ID 169.254.204.245, local router ID 192.168.115.130 BGP state = Established, up for 01:54:51 Last read 00:00:10, Last write 00:00:10 Hold time is 30, keepalive interval is 10 seconds Configured hold time is 30, keepalive interval is 10 seconds Neighbor capabilities: 4 Byte AS: advertised and received AddPath: IPv4 Unicast: RX advertised IPv4 Unicast Route refresh: advertised and received(old & new) Address Family IPv4 Unicast: advertised and received Hostname Capability: advertised (name: vyos,domain name: n/a) not received Graceful Restart Capabilty: advertised Message statistics: Inq depth is 0 Outq depth is 0 Sent Rcvd Opens: 1 1 Notifications: 0 0 Updates: 2 2 Keepalives: 689 690 Route Refresh: 0 0 Capability: 0 0 Total: 692 693 Minimum time between advertisement runs is 0 seconds For address family: IPv4 Unicast Update group 1, subgroup 1 Packet Queue length 0 Community attribute sent to this neighbor(all) 1 accepted prefixes Connections established 1; dropped 0 Last reset 01:54:53, Waiting for peer OPEN Local host: 169.254.204.246, Local port: 54076 Foreign host: 169.254.204.245, Foreign port: 179 Nexthop: 169.254.204.246 Nexthop global: fe80::5efe:c0a8:7382 Nexthop local: fe80::5efe:c0a8:7382 BGP connection: shared network BGP Connect Retry Timer in Seconds: 120 Estimated round trip time: 32 ms Read thread: on Write thread: on FD used: 27 vyos@vyos:~$ show ip route Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP, T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP, F - PBR, f - OpenFabric, > - selected route, * - FIB route, q - queued route, r - rejected route S>* 0.0.0.0/0 [210/0] via 192.168.115.2, eth0, 01:54:57 S 169.254.204.244/30 [1/0] is directly connected, vti0, 01:54:54 C>* 169.254.204.244/30 is directly connected, vti0, 01:54:54 B>* 172.31.0.0/16 [20/100] via 169.254.204.245, vti0, 01:54:53 C>* 192.168.1.0/24 is directly connected, eth1, 01:54:59 C>* 192.168.115.0/24 is directly connected, eth0, 01:54:58 vyos@vyos:~$
先日、デプロイしたVyOS 1.2.9 LTSを利用してAWSとの間で静的ルートを利用するIPsec VPNを試してみました。今回はVTIインターフェイスを使わない設定を試しました。なお、長時間の通信試験はしていません。利用した環境は、以下の通りです。
<利用した環境>
<利用した構成図>
vyos@vyos:~$ show configuration commandsset interfaces ethernet eth0 address 'dhcp'set interfaces ethernet eth0 duplex 'auto'set interfaces ethernet eth0 hw-id '00:0c:29:f3:72:11'set interfaces ethernet eth0 smp-affinity 'auto'set interfaces ethernet eth0 speed 'auto'set interfaces ethernet eth1 address '192.168.0.1/24'set interfaces ethernet eth1 duplex 'auto'set interfaces ethernet eth1 hw-id '00:0c:29:f3:72:1b'set interfaces ethernet eth1 smp-affinity 'auto'set interfaces ethernet eth1 speed 'auto'set service ssh port '22'set system config-management commit-revisions '100'set system console device ttyS0 speed '9600'set system host-name 'vyos'set system login user vyos authentication encrypted-password '<VyOS-Password>'set system login user vyos authentication plaintext-password ''set system login user vyos level 'admin'set system ntp server 133.243.238.243set system syslog global facility all level 'notice'set system syslog global facility protocols level 'debug'set system time-zone 'Asia/Tokyo'set vpn ipsec esp-group esp-grp-01 compression 'disable'set vpn ipsec esp-group esp-grp-01 lifetime '3600'set vpn ipsec esp-group esp-grp-01 mode 'tunnel'set vpn ipsec esp-group esp-grp-01 pfs 'dh-group21'set vpn ipsec esp-group esp-grp-01 proposal 1 encryption 'aes256'set vpn ipsec esp-group esp-grp-01 proposal 1 hash 'sha256'set vpn ipsec ike-group ike-grp-01 close-action 'none'set vpn ipsec ike-group ike-grp-01 dead-peer-detection action 'restart'set vpn ipsec ike-group ike-grp-01 dead-peer-detection interval '10'set vpn ipsec ike-group ike-grp-01 dead-peer-detection timeout '120'set vpn ipsec ike-group ike-grp-01 ikev2-reauth 'no'set vpn ipsec ike-group ike-grp-01 key-exchange 'ikev2'set vpn ipsec ike-group ike-grp-01 lifetime '28800'set vpn ipsec ike-group ike-grp-01 proposal 1 dh-group '21'set vpn ipsec ike-group ike-grp-01 proposal 1 encryption 'aes256'set vpn ipsec ike-group ike-grp-01 proposal 1 hash 'sha256'set vpn ipsec ipsec-interfaces interface 'eth0'set vpn ipsec nat-traversal 'enable'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] authentication mode 'pre-shared-secret'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] authentication pre-shared-secret '<pre-shared key1>'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] connection-type 'initiate'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] default-esp-group 'esp-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] description 'AWS-VPC-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] ike-group 'ike-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] ikev2-reauth 'inherit'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] local-address '192.168.115.130'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 allow-nat-networks 'disable'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 allow-public-networks 'disable'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 esp-group 'esp-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 local prefix '192.168.0.0/24'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 protocol 'all'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP1] tunnel 1 remote prefix '172.31.0.0/16'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] authentication mode 'pre-shared-secret'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] authentication pre-shared-secret '<pre-shared key2>'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] connection-type 'initiate'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] default-esp-group 'esp-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] description 'AWS-VPC-02'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] ike-group 'ike-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] ikev2-reauth 'inherit'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] local-address '192.168.115.130'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 allow-nat-networks 'disable'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 allow-public-networks 'disable'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 esp-group 'esp-grp-01'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 local prefix '192.168.0.0/24'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 protocol 'all'set vpn ipsec site-to-site peer [AWS-VirtualPrivateGateway-IP2] tunnel 1 remote prefix '172.31.0.0/16'vyos@vyos:~$
vyos@vyos:~$ show vpn ike saPeer ID / IP Local ID / IP------------ -------------[AWS-VirtualPrivateGateway-IP1] 192.168.115.130Description: AWS-VPC-01State IKEVer Encrypt Hash D-H Group NAT-T A-Time L-Time----- ------ ------- ---- --------- ----- ------ ------up IKEv2 aes256 sha256_128 21(ECP_521) no 3600 28800Peer ID / IP Local ID / IP------------ -------------[AWS-VirtualPrivateGateway-IP2] 192.168.115.130Description: AWS-VPC-02State IKEVer Encrypt Hash D-H Group NAT-T A-Time L-Time----- ------ ------- ---- --------- ----- ------ ------up IKEv2 aes256 sha256_128 21(ECP_521) no 3600 28800vyos@vyos:~$vyos@vyos:~$ show vpn ipsec saConnection State Up Bytes In/Out Remote address Remote ID Proposal--------------------------- ------- ---------- -------------- ---------------- ----------- -------------------------------------------------------peer-[AWS-VirtualPrivateGateway-IP1]-tunnel-1 up 39 minutes 38K/54K [AWS-VirtualPrivateGateway-IP1] N/A AES_CBC_256/HMAC_SHA2_256_128/PRF_HMAC_SHA2_256/ECP_521peer-[AWS-VirtualPrivateGateway-IP2]-tunnel-1 up 39 minutes 0B/0B [AWS-VirtualPrivateGateway-IP2] N/A AES_CBC_256/HMAC_SHA2_256_128/PRF_HMAC_SHA2_256/ECP_521vyos@vyos:~$vyos@vyos:~$ show ip routeCodes: K - kernel route, C - connected, S - static, R - RIP,O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,F - PBR, f - OpenFabric,> - selected route, * - FIB route, q - queued route, r - rejected routeS>* 0.0.0.0/0 [210/0] via 192.168.115.2, eth0, 00:45:20C>* 192.168.0.0/24 is directly connected, eth1, 00:45:19C>* 192.168.115.0/24 is directly connected, eth0, 00:45:21vyos@vyos:~$
先日、VyOS 1.2.9LTSが無料ダウンロードできることを知りました。
今回は、試しにPCにインストールしているVMware Workstation PlayerでVyOS 1.2.9 LTSを動かしてみました。
VMware Workstation PlayerはWindows上で仮想マシンを動かすことができるソフトウェアです。VMware Workstation Playerは非商用利用であれば無料で利用できます。以下よりダウンロードできます。
VMware Workstation Player
https://www.vmware.com/products/workstation-player.html
製品のダウンロード
https://customerconnect.vmware.com/jp/downloads/#all_products
今回はVyOSのWebサイトからダウンロードしたVyOSのOVAファイルを利用してVMware Workstation PlayerにVyOS仮想マシンをデプロイします。
利用したOVAファイルとVMware Workstation環境は以下となります。
以下のドキュメントにVyOSの最小システム要件は、512 MiB RAM と 2 GiB ストレージと記載されています。
Docs » Installation and Image Management » Installation
私は簡単に試したいだけなので、RAM4GBはちょっとオーバースペックかもしれませんね。
仮想マシンを停止してから仮想マシンの利用リソースを調整します。
今回はRAM1GBとしました。
VyOSのブログを眺めていたら、以下の投稿をみつけました。
Community support for open-source and why it's important
https://blog.vyos.io/community-support-for-open-source
このブログの最後に「古いソフトウェアリリースの無料提供の要望が多いので検討している」と書かれていました。数年前までVyOSのWebサイトでバージョン1.1.8のソフトウェアイメージが無料でダウンロードできましたが、いつからかWebサイトから無料で入手できるソフトウェアは、日々更新される最新版の「ナイトリービルド」のみになっていました。
VyOS Nightly Build
上記のブログ記事によると、今でも過去に提供されていたVyOS 1.1.xが利用されているケースが多いこともあり安全性と機能性の維持やVyOSへの関心を高めるために古いソフトウェアイメージ(VyOS 1.2.9 LTS )を無料で提供することを検討する、とのことでした。
VyOSのバージョンv1.2.9が提供されているのか、ダウンロードサイトで確認してみたところ、なんと、、、
提供が開始されてました!今でも検証用途でv1.1.xを利用されている方は、この機会に試しにv1.2.9を利用してみてはいかがでしょうか?
v1.2.xで何ができるか?については、以下のDocsが参考になるかもしれません。
VyOS User Guide
https://docs.vyos.io/en/crux/
GitHub vyos/vyos-documentation
久しぶりにVyOSのDocsを眺めていたら、コンテナが動くようになっていたのですね。
VyOS Configuration Guide » Container
https://docs.vyos.io/en/equuleus/configuration/container/index.html
簡単に試してみました。
利用したVyOSのイメージは以下となります。
Version: VyOS 1.4-rolling-202302150317
今回は、Zabbix-applianceのイメージを利用します。
Zabbixアプライアンスのコンテナイメージ:zabbix/zabbix-appliance
参考:VMware Photon OSでお手軽Zabbix検証環境構築
https://techblog-cidept.blogspot.com/2022/03/vmware-photon-oszabbix.html
※本誌で試したときのZabbix-applianceのコンテナイメージはZabbixバージョン4.4.6でした。
VyOSの設定手順は以下の通りです。
add container image zabbix/zabbix-appliance
2. コンテナを利用するための設定を追加
Configuration Mode(#~)より以下のコマンドでVyOSにコンテナの設定を追加します。
set container name zabbix-appliance allow-host-networks
set container name zabbix-appliance image 'zabbix/zabbix-appliance'
set container name zabbix-appliance port 80 destination '80'
set container name zabbix-appliance port 80 protocol 'tcp'
set container name zabbix-appliance port 80 source '80'
最後にcommitします。
実際に動作しているか確認してみましょう。
まず、VyOSのインターフェースアドレスを確認します。
192.168.115.129が設定されています。
Zabbixが起動しており、ログインできることを確認します。
コンテナを利用して何をしようか、、、
それでは。
VyOSのサイトを久しぶりに眺めていたら、Google Authenticatorなどで利用されている「TOTP(時間ベースのワンタイム パスワード)」による2要素認証が利用できるようになったというアップデート情報を見つけました。
VyOS Project November 2022 Update
https://blog.vyos.io/vyos-project-november-2022-update
Support for Two Factor Authentication for CLI access via Google Authenticator
どのように利用できるのか、簡単に試してみました。
試したときのイメージは以下になります。
Version: VyOS 1.4-rolling-202302150317
VyOS側の設定は、以下のコマンドを設定するだけです。
set system login user <user> authentication otp key <key>
set system login user <user> authentication otp rate_limit <rate_limit>
set system login user <user> authentication otp rate_time <rate_time>
set system login user <user> authentication otp window_size <window_size>
<注意点など>
・初めて試すときはログインできなくなっても困らない環境やアカウントで試してください
私は最初に試したときに確認コードが合わずログインできなくなりました
・keyに設定できる文字列はBase32かつ26文字以上が必須条件です。
・Base32はA~Z、2~7の文字列を利用します。(OやIは避けた方が良いかもしれません)
今回試したときは、以下のように設定しました。
set system login user vyos authentication otp key '234567abcdefg234567abcdefg'
set system login user vyos authentication otp rate_limit 3
set system login user vyos authentication otp rate_time 30
set system login user vyos authentication otp window_size 3
これでCommitすればVyOS側の設定は完了です。
今回の確認では、Google Authenticatorを利用します。
Google Authenticatorの設定は、以下となります。
設定は以上です。
設定されたVyOSにログインしてみましょう。
SSHでVyOSにログインすると、パスワード認証を通過したあとに以下のように認証コードの入力が求められます。
コンソールログインのときも同様に認証コードが必要になります。
それでは。
先日、ネットワークの検証をしていた時の話。。
検証時にVyOSを利用していたら、利用したい機能が
OSバージョン1.1.8では搭載されていないことが判明。
久々にVyOSのサイトをのぞきに行ったら、なんとびっくり。
サイトがだいぶ変わっとる。。。
サイトはこちら。
VyOS
VyOS、だいぶ変わりましたね。
今回、久々にサイトを見て知った新たな発見。。
その1:LTS版ソフトウェア提供が有償に、、
個人利用でも年間$660、、。私には高いわ。。
無償は、ローリング版のみ。
このブログ投稿時の最新は、安定版が1.2.6、ローリング版は1.4。
検証で簡単に試すくらいならローリング版でも十分かなと思います。
ちなみにバージョン1.1.8もまだダウンロードできるみたい。
ローリング版が嫌な場合は、こっちのほうが良いかも。
https://support.vyos.io/en/downloads/files/vyos-1-1-8-iso
その2:有償サポートも登場、、
OS+サポートがセットになった年間サブスクリプションもできたのですね。
https://vyos.io/subscriptions/support/
その3:ドキュメントが充実した気がする。。
勘違いかもしれませんが、数年前よりも情報がかなり多くて説明が増えた気がします。
VyOSのドキュメント
https://docs.vyos.io/en/latest/index.html
OS変更履歴
https://docs.vyos.io/en/latest/changelog/index.html
バージョン1.2以降では、ルーティングエンジンにFRRoutingを使用しているそうです。
知らなかった。。
VyOS KB
設定のサンプル(ブループリント)
https://docs.vyos.io/en/latest/configexamples/index.html
その4:当たり前ですが)バージョンアップで機能増えてる。。
新しいバージョンだと機能も増えますよね。。
VyOS、PPPoEサーバーやIPoEサーバーになれるのですね。知りませんでした。
そのうち、試してみたいと思います。
https://support.vyos.io/en/kb/articles/pppoe-server
ロードマップも公開されてます。計画にはSD-WANも、、。
今後も新たな機能が追加されそうですね。
その5:フォーラムが活発。。
わからないことを聞く、トラブル時のヒントを探るときに良さそう。。
その6:認定ができてた
年間利用料を払ってたら試験費無料、払ってないなら$200
どんな問題がでるのか興味はあります、、。
https://vyos.io/certification/
まとめ
VyOS、まだまだ人気あるのかなと思いました。
嬉しいことにドキュメントはかなり充実した気がします。
今回ふらっとサイトを見てみたら、
PPPoEサーバーなど知らなかった機能を発見できてよかったです。
開発による機能追加は続いているようなので、今後もチェックしたいと思います。
余談
検証時やちょっとしたときにあると便利なソフトウェアルーター。
今までとりあえずVyOSで、、と思い利用していましたが、
VyOS以外にもソフトウェアルーターっていくつかありますよね。
今後はVyOSだけでなく、FRRouting、SEILなど他のソフトウェアルーターも
試してみたいと思います。
FRRouting
IIJ SEIL(有償ですけど。Amazonで売ってます。)
それでは。
例:
テンプレートした時 テンプレートから展開した時
eth0、eth1、eth2 eth3、eth4、eth5
Vyatta-Clone-Helper/clear-nic-hw-id.plGitHubにアクセスしたら”clear-nic-hw-id.pl”の内容をコピーします。
https://github.com/ivanilves/Vyatta-Clone-Helper/blob/master/clear-nic-hw-id.pl
VyOS Project Community
https://github.com/vyos
set service webproxy authentication children '5'
set service webproxy authentication credentials-ttl '60'
set service webproxy authentication ldap base-dn 'ou=Proxy,dc=lab,dc=local'
set service webproxy authentication ldap bind-dn 'CN=Administrator,CN=Users,DC=lab,DC=local'
set service webproxy authentication ldap filter-expression 'sAMAccountName=%s'
set service webproxy authentication ldap password '【Password】'
set service webproxy authentication ldap port '389'
set service webproxy authentication ldap server '192.168.129.135'
set service webproxy authentication ldap username-attribute 'samAccountName'
set service webproxy authentication ldap version '3'
set service webproxy authentication method 'ldap'
set service webproxy authentication realm 'proxy-authentication'
Microsoft Windows [Version 10.0.14393]
(c) 2016 Microsoft Corporation. All rights reserved.
C:\Windows\system32>dsquery user -name *proxy*
"CN=proxy user1,OU=Proxy,DC=lab,DC=local"
"CN=proxy user2,OU=Proxy,DC=lab,DC=local"
"CN=proxy user3,OU=Proxy,DC=lab,DC=local"
"CN=proxy admin,OU=Proxy,DC=lab,DC=local"
"CN=proxy not-user1,CN=Users,DC=lab,DC=local"
"CN=proxy not-user2,CN=Users,DC=lab,DC=local"
"CN=proxy not-user3,CN=Users,DC=lab,DC=local"
C:\Windows\system32>
実際にクライアントPCからIEを起動してインターネットを閲覧します。IEを起動すると下記ポップアップが表示されます。アカウントとパスワードを入力し、OKをクリックします。
vyos@vyos# sudo tail -n 81 /var/log/squid3/access.log
192.168.129.146 - - [13/May/2018:23:53:51 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3733 TCP_DENIED:NONE
192.168.129.146 - lab\proxy%20user1 [13/May/2018:23:53:51 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3836 TCP_DENIED:NONE
192.168.129.146 - - [13/May/2018:23:53:51 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3733 TCP_DENIED:NONE
192.168.129.146 - lab\proxy%20user1 [13/May/2018:23:53:51 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3836 TCP_DENIED:NONE
192.168.129.146 - - [13/May/2018:23:54:07 +0900] "GET http://www.msn.com/ja-jp/? HTTP/1.1" 407 5017 TCP_DENIED:NONE
192.168.129.146 - lab\proxy%20user1 [13/May/2018:23:54:07 +0900] "GET http://www.msn.com/ja-jp/? HTTP/1.1" 407 5120 TCP_DENIED:NONE
192.168.129.146 - proxy-user1 [13/May/2018:23:55:33 +0900] "GET http://www.msn.com/ja-jp/? HTTP/1.1" 200 423924 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:55:34 +0900] "GET http://www.msn.com/ja-jp/homepage/irisbannerajax HTTP/1.1" 204 872 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:55:34 +0900] "GET http://otf.msn.com/c.gif? HTTP/1.1" 200 664 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:55:34 +0900] "CONNECT sb.scorecardresearch.com:443 HTTP/1.0" 200 5464 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:55:34 +0900] "OPTIONS http://otf.msn.com/c.gif? HTTP/1.1" 200 468 TCP_MISS:DIRECT
## 中略 ##
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT px.ads.linkedin.com:443 HTTP/1.0" 200 3512 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT sam.msn.com:443 HTTP/1.0" 200 36954 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT sam.msn.com:443 HTTP/1.0" 200 5615 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT choices.truste.com:443 HTTP/1.0" 200 16875 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT ad.adsrvr.org:443 HTTP/1.0" 200 64868 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT www.msn.com:443 HTTP/1.0" 200 6308 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:19 +0900] "CONNECT pr-bh.ybp.yahoo.com:443 HTTP/1.0" 200 5365 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:57:20 +0900] "GET http://ping.chartbeat.net/ping? HTTP/1.1" 200 362 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [13/May/2018:23:58:35 +0900] "GET http://ping.chartbeat.net/ping? HTTP/1.1" 200 362 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [14/May/2018:00:00:28 +0900] "GET http://sin1-ib.adnxs.com/vevent? HTTP/1.1" 200 905 TCP_MISS:DIRECT
192.168.129.146 - proxy-user1 [14/May/2018:00:00:50 +0900] "GET http://ping.chartbeat.net/ping? HTTP/1.1" 200 362 TCP_MISS:DIRECT
[edit]
vyos@vyos#
vyos@vyos# sudo tail -n 25 /var/log/squid3/access.log
192.168.129.137 - - [14/May/2018:00:48:51 +0900] "CONNECT uhf.microsoft.com:443 HTTP/1.0" 407 3847 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:48:51 +0900] "CONNECT img-prod-cms-rt-microsoft-com.akamaized.net:443 HTTP/1.0" 407 3951 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:48:56 +0900] "GET http://ipv6.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3759 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:48:56 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3755 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:48:56 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3733 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:49:26 +0900] "CONNECT ieonline.microsoft.com:443 HTTP/1.0" 407 3866 TCP_DENIED:NONE
192.168.129.137 - proxy-not-user1 [14/May/2018:00:49:26 +0900] "CONNECT ieonline.microsoft.com:443 HTTP/1.0" 407 3969 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:49:54 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3733 TCP_DENIED:NONE
192.168.129.137 - proxy-not-user1 [14/May/2018:00:49:54 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3836 TCP_DENIED:NONE
192.168.129.137 - - [14/May/2018:00:49:54 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3733 TCP_DENIED:NONE
192.168.129.137 - proxy-not-user1 [14/May/2018:00:49:54 +0900] "GET http://www.msftconnecttest.com/connecttest.txt HTTP/1.1" 407 3836 TCP_DENIED:NONE
Active Directory Diagnostic Logging
https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-2000-server/cc961809(v=technet.10)
Forums VyOS HowTos Webproxy (squid) log format
Webproxy (squid) log format
https://forum.vyos.net/showthread.php?tid=16848
sudo vi /opt/vyatta/sbin/vyatta-update-webproxy.pl
if ($config->exists('disable-access-log')) {
$output .= "access_log none\n\n";
} else {
$output .= "access_log $squid_log common\n\n"; # ←追加した行
#$output .= "access_log $squid_log squid\n\n"; # ←無効にした行
}
vyos@vyos:~$ show webproxy log | tail -n 50
192.168.129.1 - - [01/Apr/2018:23:07:02 +0900] "CONNECT ashiato.rakuten.co.jp:443 HTTP/1.1" 200 3951 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:02 +0900] "CONNECT r.r10s.jp:443 HTTP/1.1" 200 4101 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT g01.api.bookmark.rakuten.co.jp:443 HTTP/1.1" 200 5038 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT api.ranking.rakuten.co.jp:443 HTTP/1.1" 200 19316 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT api.ranking.rakuten.co.jp:443 HTTP/1.1" 200 21266 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT api.ranking.rakuten.co.jp:443 HTTP/1.1" 200 26027 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT api.ranking.rakuten.co.jp:443 HTTP/1.1" 200 15333 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT image.ias.rakuten.co.jp:443 HTTP/1.1" 200 15552 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:03 +0900] "CONNECT image.ias.rakuten.co.jp:443 HTTP/1.1" 200 15673 TCP_MISS:DIRECT
~中略~
192.168.129.1 - - [01/Apr/2018:23:07:08 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 59123 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:08 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 55855 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:08 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 39801 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:08 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 39801 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:08 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 59793 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:09 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 38421 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:09 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 39801 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:09 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 39093 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:13 +0900] "CONNECT fonts.gstatic.com:443 HTTP/1.1" 200 4385 TCP_MISS:DIRECT
192.168.129.1 - - [01/Apr/2018:23:07:19 +0900] "CONNECT images-fe.ssl-images-amazon.com:443 HTTP/1.1" 200 5301 TCP_MISS:DIRECT
vyos@vyos:~$
今回はこの辺で。それでは。