-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path2023-04-26-14_10_41.log
1088 lines (1056 loc) · 46.3 KB
/
2023-04-26-14_10_41.log
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
+ source /root/mugen/libs/locallibs/common_lib.sh
++ python3 --version
++ '[' 0 -eq 0 ']'
++ source /root/mugen/libs/locallibs/common_lib_python.sh
+ main
++ type -t post_test
+ '[' -n function ']'
+ trap post_test EXIT INT HUP TERM
+ rpm -qa
+ grep expect
++ type -t config_params
+ '[' -n '' ']'
++ type -t pre_test
+ '[' -n function ']'
+ pre_test
+ LOG_INFO 'Start to prepare the test environment.'
+ message='Start to prepare the test environment.'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level info --message 'Start to prepare the test environment.'
Wed Apr 26 14:10:47 2023 - INFO - Start to prepare the test environment.
+ DNF_INSTALL openvpn
+ pkgs=openvpn
+ node=1
+ '[' -z '' ']'
+ tmpfile=
++ python3 /root/mugen/libs/locallibs/rpm_manage.py install --pkgs openvpn --node 1 --tempfile ''
+ tmpfile2=/tmp/tmpa9am5c4t
+ '[' -z '' ']'
+ tmpfile=/tmp/tmpa9am5c4t
+ DNF_INSTALL openvpn 2
+ pkgs=openvpn
+ node=2
+ '[' -z /tmp/tmpa9am5c4t ']'
++ python3 /root/mugen/libs/locallibs/rpm_manage.py install --pkgs openvpn --node 2 --tempfile /tmp/tmpa9am5c4t
+ tmpfile2=/tmp/tmpa9am5c4t
+ '[' -z /tmp/tmpa9am5c4t ']'
+ LOG_INFO 'Finish preparing the test environment.'
+ message='Finish preparing the test environment.'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level info --message 'Finish preparing the test environment.'
Wed Apr 26 14:12:59 2023 - INFO - Finish preparing the test environment.
++ type -t run_test
+ '[' -n function ']'
+ run_test
+ LOG_INFO 'Start to run test.'
+ message='Start to run test.'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level info --message 'Start to run test.'
Wed Apr 26 14:13:00 2023 - INFO - Start to run test.
+ openvpn --help
+ grep '\--'
--config file : Read configuration options from file.
--help : Show options.
--version : Show copyright and version information.
--local host : Local host name or ip address. Implies --bind.
--remote host [port] : Remote host name or ip address.
--remote-random : If multiple --remote options specified, choose one randomly.
--remote-random-hostname : Add a random string to remote DNS name.
--mode m : Major mode, m = 'p2p' (default, point-to-point) or 'server'.
--proto p : Use protocol p for communicating with peer.
--proto-force p : only consider protocol p in list of connection profiles.
--connect-retry n [m] : For client, number of seconds to wait between
--connect-retry-max n : Maximum connection attempt retries, default infinite.
--http-proxy s p [up] [auth] : Connect to remote host
--http-proxy s p 'auto[-nct]' : Like the above directive, but automatically
--http-proxy-option type [parm] : Set extended HTTP proxy options.
--socks-proxy s [p] [up] : Connect to remote host through a Socks5 proxy at
--socks-proxy-retry : Retry indefinitely on Socks proxy errors.
--resolv-retry n: If hostname resolve fails for --remote, retry
--float : Allow remote to change its IP address/port, such as through
DHCP (this is the default if --remote is not used).
--ipchange cmd : Run command cmd on remote ip address initial
setting or change -- execute as: cmd ip-address port#
--port port : TCP/UDP port # for both local and remote.
--lport port : TCP/UDP port # for local (default=1194). Implies --bind.
--rport port : TCP/UDP port # for remote (default=1194).
--bind : Bind to local address and port. (This is the default unless
--proto tcp-client or --http-proxy or --socks-proxy is used).
--nobind : Do not bind to local address and port.
--dev tunX|tapX : tun/tap device (X can be omitted for dynamic device.
--dev-type dt : Which device type are we using? (dt = tun or tap) Use
this option only if the tun/tap device used with --dev
--dev-node node : Explicitly set the device node rather than using
--lladdr hw : Set the link layer address of the tap device.
--topology t : Set --dev tun topology: 'net30', 'p2p', or 'subnet'.
--iproute cmd : Use this command instead of default /sbin/ip.
--ifconfig l rn : TUN: configure device to use IP address l as a local
--ifconfig-ipv6 l r : configure device to use IPv6 address l as local
--ifconfig-noexec : Don't actually execute ifconfig/netsh command, instead
pass --ifconfig parms by environment to scripts.
--ifconfig-nowarn : Don't warn if the --ifconfig option on this side of the
--route network [netmask] [gateway] [metric] :
gateway default: taken from --route-gateway or --ifconfig
--route-ipv6 network/bits [gateway] [metric] :
gateway default: taken from --route-ipv6-gateway or 'remote'
in --ifconfig-ipv6
--route-gateway gw|'dhcp' : Specify a default gateway for use with --route.
--route-ipv6-gateway gw : Specify a default gateway for use with --route-ipv6.
--route-metric m : Specify a default metric for use with --route.
--route-delay n [w] : Delay n seconds after connection initiation before
--route-up cmd : Run command cmd after routes are added.
--route-pre-down cmd : Run command cmd before routes are removed.
--route-noexec : Don't add routes automatically. Instead pass routes to
--route-up script using environmental variables.
--route-nopull : When used with --client or --pull, accept options pushed
--allow-pull-fqdn : Allow client to pull DNS names from server for
--ifconfig, --route, and --route-gateway.
--redirect-gateway [flags]: Automatically execute routing
--redirect-private [flags]: Like --redirect-gateway, but omit actually changing
--block-ipv6 : (Client) Instead sending IPv6 to the server generate
--client-nat snat|dnat network netmask alias : on client add 1-to-1 NAT rule.
--push-peer-info : (client only) push client info to server.
--setenv name value : Set a custom environmental variable to pass to script.
--setenv FORWARD_COMPATIBLE 1 : Relax config file syntax checking to allow
--ignore-unkown-option opt1 opt2 ...: Relax config file syntax. Allow
--script-security level: Where level can be:
0 -- strictly no calling of external programs
1 -- (default) only call built-ins such as ifconfig
2 -- allow calling of built-ins and scripts
3 -- allow password to be passed to scripts via env
--shaper n : Restrict output to peer to n bytes per second.
--keepalive n m : Helper option for setting timeouts in server mode. Send
--inactive n [bytes] : Exit after n seconds of activity on tun/tap device
--ping-exit n : Exit if n seconds pass without reception of remote ping.
--ping-restart n: Restart if n seconds pass without reception of remote ping.
--ping-timer-rem: Run the --ping-exit/--ping-restart timer only if we have a
--ping n : Ping remote once every n seconds over TCP/UDP port.
--multihome : Configure a multi-homed UDP server.
--fast-io : (experimental) Optimize TUN/TAP/UDP writes.
--remap-usr1 s : On SIGUSR1 signals, remap signal (s='SIGHUP' or 'SIGTERM').
--persist-tun : Keep tun/tap device open across SIGUSR1 or --ping-restart.
--persist-remote-ip : Keep remote IP address across SIGUSR1 or --ping-restart.
--persist-local-ip : Keep local IP address across SIGUSR1 or --ping-restart.
--persist-key : Don't re-read key files across SIGUSR1 or --ping-restart.
--passtos : TOS passthrough (applies to IPv4 only).
--tun-mtu n : Take the tun/tap device MTU to be n and derive the
--tun-mtu-extra n : Assume that tun/tap device might return as many
--link-mtu n : Take the TCP/UDP device MTU to be n and derive the tun MTU
--mtu-disc type : Should we do Path MTU discovery on TCP/UDP channel?
'no' -- Never send DF (Don't Fragment) frames
'maybe' -- Use per-route hints
'yes' -- Always DF (Don't Fragment)
--mtu-test : Empirically measure and report MTU.
--fragment max : Enable internal datagram fragmentation so that no UDP
--mssfix [n] : Set upper bound on TCP MSS, default = tun-mtu size
or --fragment max value, whichever is lower.
--sndbuf size : Set the TCP/UDP send buffer size.
--rcvbuf size : Set the TCP/UDP receive buffer size.
--mark value : Mark encrypted packets being sent with value. The mark value
--bind-dev dev : Bind to the given device when making connection to a peer or
--txqueuelen n : Set the tun/tap TX queue length to n (Linux only).
--memstats file : Write live usage stats to memory mapped binary file.
--mlock : Disable Paging -- ensures key material and tunnel
--up cmd : Run command cmd after successful tun device open.
(pre --user or --group UID/GID change)
--up-delay : Delay tun/tap open and possible --up script execution
--down cmd : Run command cmd after tun device close.
(post --user/--group UID/GID change and/or --chroot)
(command parameters are same as --up option)
--down-pre : Run --down command before TUN/TAP close.
--up-restart : Run up/down commands for all restarts including those
caused by --ping-restart or SIGUSR1
--user user : Set UID to user after initialization.
--group group : Set GID to group after initialization.
--chroot dir : Chroot to this directory after initialization.
--setcon context: Apply this SELinux context after initialization.
--cd dir : Change to this directory before initialization.
--daemon [name] : Become a daemon after initialization.
--syslog [name] : Output to syslog, but do not become a daemon.
See --daemon above for a description of the 'name' parm.
--inetd [name] ['wait'|'nowait'] : Run as an inetd or xinetd server.
See --daemon above for a description of the 'name' parm.
--log file : Output log to file which is created/truncated on open.
--log-append file : Append log to file, or create file if nonexistent.
--suppress-timestamps : Don't log timestamps to stdout/stderr.
--machine-readable-output : Always log timestamp, message flags to stdout/stderr.
--writepid file : Write main process ID to file.
--nice n : Change process priority (>0 = lower, <0 = higher).
--echo [parms ...] : Echo parameters to log output.
--verb n : Set output verbosity to n (default=1):
: 0 -- no output except fatal errors
: 1 -- startup info + connection initiated messages +
: 2,3 -- show TLS negotiations & route info
: 4 -- show parameters
: 5 -- show 'RrWw' chars on console for each packet sent
: 6 to 11 -- debug messages of increasing verbosity
--mute n : Log at most n consecutive messages in the same category.
--status file n : Write operational status to file every n seconds.
--status-version [n] : Choose the status file format version number.
--disable-occ : Disable options consistency check between peers.
--gremlin mask : Special stress testing mode (for debugging only).
--compress alg : Use compression algorithm alg
--allow-compression: Specify whether compression should be allowed
--comp-lzo : Use LZO compression -- may add up to 1 byte per
--comp-noadapt : Don't use adaptive compression when --comp-lzo
--management ip port [pass] : Enable a TCP server on ip:port to handle
--management-client : Management interface will connect as a TCP client to
--management-query-passwords : Query management channel for private key
--management-query-proxy : Query management channel for proxy information.
--management-query-remote : Query management channel for --remote directive.
--management-hold : Start OpenVPN in a hibernating state, until a client
--management-signal : Issue SIGUSR1 when management disconnect event occurs.
--management-forget-disconnect : Forget passwords when management disconnect
--management-up-down : Report tunnel up/down events to management interface.
--management-log-cache n : Cache n lines of log file history for usage
--management-client-user u : When management interface is a unix socket, only
--management-client-group g : When management interface is a unix socket, only
--management-client-auth : gives management interface client the responsibility
--management-client-pf : management interface clients must specify a packet
--plugin m [str]: Load plug-in module m passing str as an argument
--vlan-tagging : Enable 802.1Q-based VLAN tagging.
--vlan-accept tagged|untagged|all : Set VLAN tagging mode. Default is 'all'.
--vlan-pvid v : Sets the Port VLAN Identifier. Defaults to 1.
Multi-Client Server options (when --mode server is used):
--server network netmask : Helper option to easily configure server mode.
--server-ipv6 network/bits : Configure IPv6 server mode.
--server-bridge [IP netmask pool-start-IP pool-end-IP] : Helper option to
--push "option" : Push a config file option back to the peer for remote
execution. Peer must specify --pull in its config file.
--push-reset : Don't inherit global push list for specific
--push-remove opt : Remove options matching 'opt' from the push list for
--ifconfig-pool start-IP end-IP [netmask] : Set aside a pool of subnets
--ifconfig-pool-persist file [seconds] : Persist/unpersist ifconfig-pool
--ifconfig-ipv6-pool base-IP/bits : set aside an IPv6 network block
--ifconfig-push local remote-netmask : Push an ifconfig option to remote,
overrides --ifconfig-pool dynamic allocation.
--ifconfig-ipv6-push local/bits remote : Push an ifconfig-ipv6 option to
remote, overrides --ifconfig-ipv6-pool allocation.
--iroute network [netmask] : Route subnet to client.
--iroute-ipv6 network/bits : Route IPv6 subnet to client.
--disable : Client is disabled.
--verify-client-cert [none|optional|require] : perform no, optional or
--username-as-common-name : For auth-user-pass authentication, use
--auth-user-pass-verify cmd method: Query client for username/password and
--auth-gen-token [lifetime] Generate a random authentication token which is pushed
--reneg-* options are enabled. Optionally a lifetime in seconds
--opt-verify : Clients that connect with options that are incompatible
--auth-user-pass-optional : Allow connections by clients that don't
--no-name-remapping : (DEPRECATED) Allow Common Name and X509 Subject to include
--client-to-client : Internally route client-to-client traffic.
--duplicate-cn : Allow multiple clients with the same common name to
--client-connect cmd : Run command cmd on client connection.
--client-disconnect cmd : Run command cmd on client disconnection.
--client-config-dir dir : Directory for custom client config files.
--ccd-exclusive : Refuse connection unless custom client config is found.
--tmp-dir dir : Temporary directory, used for --client-connect return file and plugin communication.
--hash-size r v : Set the size of the real address hash table to r and the
--bcast-buffers n : Allocate n broadcast buffers.
--tcp-queue-limit n : Maximum number of queued TCP output packets.
--tcp-nodelay : Macro that sets TCP_NODELAY socket flag on the server
--learn-address cmd : Run command cmd to validate client virtual addresses.
--connect-freq n s : Allow a maximum of n new connections per s seconds.
--max-clients n : Allow a maximum of n simultaneously connected clients.
--max-routes-per-client n : Allow a maximum of n internal routes per client.
--stale-routes-check n [t] : Remove routes with a last activity timestamp
--explicit-exit-notify [n] : In UDP server mode send [RESTART] command on exit/restart to connected
--port-share host port [dir] : When run in TCP mode, proxy incoming HTTPS
--client : Helper option to easily configure client mode.
--auth-user-pass [up] : Authenticate with server using username/password.
--pull : Accept certain config file options from the peer as if they
when connecting to a '--mode server' remote host.
--pull-filter accept|ignore|reject t : Filter each option received from the
--auth-retry t : How to handle auth failures. Set t to
--static-challenge t e : Enable static challenge/response protocol using
--connect-timeout n : when polling possible remote servers to connect to
--allow-recursive-routing : When this option is set, OpenVPN will not drop
--explicit-exit-notify [n] : On exit/restart, send exit signal to
--secret f [d] : Enable Static Key encryption mode (non-TLS).
Use shared secret file f, generate with --genkey.
--auth alg : Authenticate packets with HMAC using message
--cipher alg : Encrypt packets with cipher algorithm alg
--data-ciphers list : List of ciphers that are allowed to be negotiated.
--ncp-disable : (DEPRECATED) Disable cipher negotiation.
--prng alg [nsl] : For PRNG, use digest algorithm alg, and
--keysize n : (DEPRECATED) Size of cipher key in bits (optional).
--engine [name] : Enable OpenSSL hardware crypto engine functionality.
--no-replay : (DEPRECATED) Disable replay protection.
--mute-replay-warnings : Silence the output of replay warnings to log file.
--replay-window n [t] : Use a replay protection sliding window of size n
--replay-persist file : Persist replay-protection state across sessions
--test-crypto : Run a self-test of crypto features enabled.
--tls-server : Enable TLS and assume server role during TLS handshake.
--tls-client : Enable TLS and assume client role during TLS handshake.
--key-method m : (DEPRECATED) Data channel key exchange method. m should be a method
--ca file : Certificate authority file in .pem format containing
--capath dir : A directory of trusted certificates (CAs and CRLs).
--dh file : File containing Diffie Hellman parameters
in .pem format (for --tls-server only).
--cert file : Local certificate in .pem format -- must be signed
by a Certificate Authority in --ca file.
--extra-certs file : one or more PEM certs that complete the cert chain.
--key file : Local private key in .pem format.
--tls-version-min <version> ['or-highest'] : sets the minimum TLS version we
--tls-version-max <version> : sets the maximum TLS version we will use.
--pkcs12 file : PKCS#12 file containing local private key, local certificate
--x509-username-field : Field in x509 certificate containing the username.
--verify-hash hash [algo] : Specify fingerprint for level-1 certificate.
--tls-cipher l : A list l of allowable TLS ciphers separated by : (optional).
--tls-ciphersuites l: A list of allowed TLS 1.3 cipher suites seperated by : (optional)
: Use --show-tls to see a list of supported TLS ciphers (suites).
--tls-cert-profile p : Set the allowed certificate crypto algorithm profile
--providers l : A list l of OpenSSL providers to load.
--tls-timeout n : Packet retransmit timeout on TLS control channel
--reneg-bytes n : Renegotiate data chan. key after n bytes sent and recvd.
--reneg-pkts n : Renegotiate data chan. key after n packets sent and recvd.
--reneg-sec max [min] : Renegotiate data chan. key after at most max (default=3600)
--hand-window n : Data channel key exchange must finalize within n seconds
--tran-window n : Transition window -- old key can live this many seconds
--single-session: Allow only one session (reset state on restart).
--tls-exit : Exit on TLS negotiation failure.
--tls-auth f [d]: Add an additional layer of authentication on top of the TLS
see --secret option for more info.
--tls-crypt key : Add an additional layer of authenticated encryption on top
see --secret option for more info.
--tls-crypt-v2 key : For clients: use key as a client-specific tls-crypt key.
key generation (--genkey tls-crypt-v2-client): use key to
encrypt generated client-specific key. (See --tls-crypt.)
--genkey tls-crypt-v2-client [keyfile] [base64 metadata]: Generate a
--genkey tls-crypt-v2-server [keyfile] [base64 metadata]: Generate a
--tls-crypt-v2-verify cmd : Run command cmd to verify the metadata of the
--askpass [file]: Get PEM password from controlling tty before we daemonize.
--auth-nocache : Don't cache --askpass or --auth-user-pass passwords.
--crl-verify crl ['dir']: Check peer certificate against a CRL.
--tls-verify cmd: Run command cmd to verify the X509 name of a
--tls-export-cert [directory] : Get peer cert in PEM format and store it
--verify-x509-name name: Accept connections only from a host with X509 subject
--ns-cert-type t: (DEPRECATED) Require that peer certificate was signed with
--x509-track x : Save peer X509 attribute x in environment for use by
--keying-material-exporter label len : Save Exported Keying Material (RFC5705)
--remote-cert-ku v ... : Require that the peer certificate was signed with
--remote-cert-eku oid : Require that the peer certificate was signed with
--remote-cert-tls t: Require that peer certificate was signed with explicit
--pkcs11-providers provider ... : PKCS#11 provider to load.
--pkcs11-protected-authentication [0|1] ... : Use PKCS#11 protected authentication
--pkcs11-private-mode hex ... : PKCS#11 private key mode mask.
--pkcs11-cert-private [0|1] ... : Set if login should be performed before
--pkcs11-pin-cache seconds : Number of seconds to cache PIN. The default is -1
--pkcs11-id-management : Acquire identity from management interface.
--pkcs11-id serialized-id 'id' : Identity to use, get using standalone --show-pkcs11-ids
--show-ciphers : Show cipher algorithms to use with --cipher option.
--show-digests : Show message digest algorithms to use with --auth option.
--show-engines : Show hardware crypto accelerator engines (if available).
--show-tls : Show all TLS ciphers (TLS used only as a control channel).
--genkey secret file : Generate a new random key of type and write to file
(for use with --secret, --tls-auth or --tls-crypt).
--mktun : Create a persistent tunnel.
--rmtun : Remove a persistent tunnel.
--dev tunX|tapX : tun/tap device
--dev-type dt : Device type. See tunnel options above for details.
--user user : User to set privilege to.
--group group : Group to set privilege to.
--show-pkcs11-ids provider [cert_private] : Show PKCS#11 available ids.
--verb option can be added *BEFORE* this.
--show-gateway : Show info about default gateway.
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ openvpn --version
+ grep OpenVPN
OpenVPN 2.5.8 riscv64-openEuler-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Mar 20 2023
Copyright (C) 2002-2022 OpenVPN Inc <[email protected]>
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ touch tt.vpn
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ SLEEP_WAIT 5
+ wait_time=5
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 5 --cmd '' --mode 1
+ nohup openvpn --local 127.0.0.1 --config tt.vpn --dev tun1 --ifconfig 10.4.0.1 10.4.0.2 --verb 9
+ pgrep -f 'openvpn --local'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 41'
+ message='oe_test_openvpn.sh line 41'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 41'
Wed Apr 26 14:13:07 2023 - ERROR - oe_test_openvpn.sh line 41
+ '[' 0 -eq 1 ']'
+ return 0
+ ping -c 3 10.4.0.1
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 43'
+ message='oe_test_openvpn.sh line 43'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 43'
Wed Apr 26 14:13:10 2023 - ERROR - oe_test_openvpn.sh line 43
+ '[' 0 -eq 1 ']'
+ return 0
++ pgrep -f 'openvpn --local'
+ kill -9
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ pgrep -f 'openvpn --local'
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ pgrep -f 'openvpn --remote'
+ nohup openvpn --remote 10.198.114.6 --dev tun1 --ifconfig 10.4.0.1 10.4.0.2 --verb 9
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 53'
+ message='oe_test_openvpn.sh line 53'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 53'
Wed Apr 26 14:13:28 2023 - ERROR - oe_test_openvpn.sh line 53
+ '[' 0 -eq 1 ']'
+ return 0
+ P_SSH_CMD --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --verb 9 >/dev/null 2>&1 &'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --verb 9 >/dev/null 2>&1 &'
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
++ P_SSH_CMD --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ tail -n 1
++ awk -F '\r' '{print $1}'
+ remote_pid=
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ ping -c 3 10.4.0.2
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 61'
+ message='oe_test_openvpn.sh line 61'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 61'
Wed Apr 26 14:13:51 2023 - ERROR - oe_test_openvpn.sh line 61
+ '[' 0 -eq 1 ']'
+ return 0
+ P_SSH_CMD --node 2 --cmd 'ping -c 3 10.4.0.1 >/dev/null'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'ping -c 3 10.4.0.1 >/dev/null'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 63'
+ message='oe_test_openvpn.sh line 63'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 63'
Wed Apr 26 14:14:02 2023 - ERROR - oe_test_openvpn.sh line 63
+ '[' 0 -eq 1 ']'
+ return 0
++ pgrep -f 'openvpn --remote'
+ kill -9
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ pgrep -f 'openvpn --remote'
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ P_SSH_CMD --node 2 --cmd 'kill -9 '
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'kill -9 '
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ P_SSH_CMD --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ openvpn --genkey --secret key
2023-04-26 14:14:59 WARNING: Using --genkey --secret filename is DEPRECATED. Use --genkey secret filename instead.
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ grep -iE '[a-z0-9]|openvpn' key
# 2048 bit OpenVPN static key
-----BEGIN OpenVPN Static key V1-----
72fa0007b390ecac48fec91a751a1174
f7911a174d7cfb9e0a806f53b0213bbc
0fd28afe67b4e595358d45e4fc007044
af42e51bba1905f7b4501711fd211cee
d8e649d4f0f03e795be3aae892d597a0
dd0ddc2cb8c438a9a1726eeefcb28f02
fed55f294de6c9890dd7491398cf887d
4943c7754f1cc2d140d27380f33a0ecb
1f2c3ecfe5f8d8281e1a4f92df65cd2f
e3f9aa9d605fa37fbc295788f1eaa6d5
fe39477805a140a6a0f645b40ad0ea7e
abe86d453ddfa18644b10f9ca0c5c0d4
84bd6b61a88696671b5776b305117392
09d0e18dce5f69d6e35da76a7a80f496
322fead9f9e2416392879dff04e187e8
b8ccf007cafc4ff261a940f81e8b8cc6
-----END OpenVPN Static key V1-----
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ SFTP put --localdir ./ --localfile key --remotedir /root --node 2
+ python3 /root/mugen/libs/locallibs/sftp.py put --localdir ./ --localfile key --remotedir /root --node 2
Wed Apr 26 14:15:09 2023 - INFO - start to put file:./key......
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ P_SSH_CMD --node 2 --cmd 'test -f key'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'test -f key'
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ SLEEP_WAIT 5
+ wait_time=5
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 5 --cmd '' --mode 1
+ nohup openvpn --remote 10.198.114.6 --dev tun1 --ifconfig 10.4.0.1 10.4.0.2 --verb 5 --secret key
+ pgrep -f 'openvpn --remote'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 87'
+ message='oe_test_openvpn.sh line 87'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 87'
Wed Apr 26 14:15:25 2023 - ERROR - oe_test_openvpn.sh line 87
+ '[' 0 -eq 1 ']'
+ return 0
+ P_SSH_CMD --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --verb 5 --secret key >/dev/null 2>&1 &'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --verb 5 --secret key >/dev/null 2>&1 &'
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
++ P_SSH_CMD --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ tail -n 1
++ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ awk -F '\r' '{print $1}'
+ remote_pid=
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ ping -c 3 10.4.0.2
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 94'
+ message='oe_test_openvpn.sh line 94'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 94'
Wed Apr 26 14:15:47 2023 - ERROR - oe_test_openvpn.sh line 94
+ '[' 0 -eq 1 ']'
+ return 0
+ P_SSH_CMD --node 2 --cmd 'ping -c 3 10.4.0.1 >/dev/null'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'ping -c 3 10.4.0.1 >/dev/null'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 96'
+ message='oe_test_openvpn.sh line 96'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 96'
Wed Apr 26 14:15:57 2023 - ERROR - oe_test_openvpn.sh line 96
+ '[' 0 -eq 1 ']'
+ return 0
++ pgrep -f 'openvpn --remote'
+ kill -9
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ pgrep -f 'openvpn --remote'
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ P_SSH_CMD --node 2 --cmd 'kill -9 '
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'kill -9 '
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ P_SSH_CMD --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ expect
spawn openssl req -nodes -new -x509 -keyout client.key -out ca.crt
.+.....+..........+......+.....+...+...+............+......+.......+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*.+.+...+......+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*.+...+.........+.....+.......+.........+......+...+......+..+...+................+.....+...+.+.....+.........+......+.+.....+......+.............+......+..............+.+........+.+.........+...+..+.+.....+.+......+.....+...+................+.........+...........+.+...+......+.....+.........+.........+......+.+...+...+..+.+.....+.+..................+...........+.+.........+..+.........+...+...+....+...+............+...+...+..+...............+.+......+.....+....+..+...+............+.............+.....+....+......+..+.........+...+...+.......+.....+.+.....+.+...+...........+.......+..+..........+........+....+......+..............+......+....+...+......+..+....+......+.....+.......+..+.+...+......+.....+.........+.+......+..............+.+...+.........+..+...+.+...........+....+.....+.+..............+.+..............+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
........+.................+......+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*.+.....+.+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*..........+.+.....+.............+.....+.......+.....+...+.+..+.......+...+........+.+...+.....+......+......+.........+.+...+...+.....+....+......+...............+.........+...+......+.........+...+..+.+..+...+....+..................+...+....................+...............+.....................+....+.........+...+...+.....+.+.....+...+.......+.........+......+........+......+......+....+..+.........+.+.....+............+.+.....+.+...+.....+...+....+......+.........+.....+....+...........+.........+.+...+..+..................+.+..+.......+............+...+............+.....+.........+.+..............+.+..............+.+...+..+.+..............+.+...+......+..................+......+...........+....+......+.........+..+....+..................+........+...................+.....+...+...+...+....+.....+.+.........+......+...........+....+.....+......+...+............+.............+..+.+.....+...............+.......+.....+......+....+..+...+.............+...+.........+.....+.......+..............................+...+..+......+..................+.......+..+.......+......+..............+.+............+...+.....+.......+..+....+..+............+.......+...........+...+.+...+......+.....+.........+.+......+......+.........+.....+.+.....+.............+..............+.+.....+.+...........+.......+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:
State or Province Name (full name) [Some-State]:
Locality Name (eg, city) []:
Organization Name (eg, company) [Internet Widgits Pty Ltd]:
Organizational Unit Name (eg, section) []:
Common Name (e.g. server FQDN or YOUR name) []:
Email Address []:
+ expect
spawn openssl req -nodes -new -x509 -keyout client.key -out client.crt
.+...+...+.....+.............+..+.......+...+..+..........+........+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*.+..........+.....+......+.......+...+.........+.....+.+..+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*..+.............+...+..+.......+.....+......+....+.................+.+............+.....+.............+.....+.......+..+....+............+.....+.......+..+.+..............+.+.................+...+....+.....+...+......+.+...+...........+.........+.+...........+.+..+...............+...+.......+..+.+...+..+...+........................................+....................+.+......+...+.........+..+.............+..+......+..........+..+...+....+...........+...+.........+.+.........+......+............+.....+...+...............+....+.................+.+..+.......+.....+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
....+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*....+............+.+..+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*............+...+...+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:
State or Province Name (full name) [Some-State]:
Locality Name (eg, city) []:
Organization Name (eg, company) [Internet Widgits Pty Ltd]:
Organizational Unit Name (eg, section) []:
Common Name (e.g. server FQDN or YOUR name) []:
Email Address []:
+ test -f client.key -a -f ca.crt -a -f client.crt
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ SLEEP_WAIT 5
+ wait_time=5
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 5 --cmd '' --mode 1
+ nohup openvpn --remote 10.198.114.6 --dev tun1 --ifconfig 10.4.0.1 10.4.0.2 --tls-client --ca ca.crt --cert client.crt --key client.key --reneg-sec 60 --verb 5
+ pgrep -f 'openvpn --remote'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 134'
+ message='oe_test_openvpn.sh line 134'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 134'
Wed Apr 26 14:17:17 2023 - ERROR - oe_test_openvpn.sh line 134
+ '[' 0 -eq 1 ']'
+ return 0
+ ping -c 3 10.4.0.1
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 136'
+ message='oe_test_openvpn.sh line 136'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 136'
Wed Apr 26 14:17:30 2023 - ERROR - oe_test_openvpn.sh line 136
+ '[' 0 -eq 1 ']'
+ return 0
++ pgrep -f 'openvpn --remote'
+ kill -9
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ pgrep -f 'openvpn --remote'
+ CHECK_RESULT 1 1
+ actual_result=1
+ expect_result=1
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 1x
+ return 0
+ expect
spawn ssh -2 [email protected]
The authenticity of host '10.198.114.6 (10.198.114.6)' can't be established.
ED25519 key fingerprint is SHA256:j2wdRtPc00KLhvK3Tj+SkYkwB1FXdanKLflYeFA0yE8.
This key is not known by any other names.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '10.198.114.6' (ED25519) to the list of known hosts.
[email protected]'s password:
Last login: Wed Apr 26 10:17:48 2023
Welcome to 6.1.8-3.oe2303.riscv64
System information as of time: Wed Apr 26 02:17:59 PM CST 2023
System load: [0;33;40m1.49[0m
Processes: 112
Memory used: 2.6%
Swap used: 0.0%
Usage On: 26%
IP address: 10.198.114.6
IP address: 10.0.2.15
Users online: 1
[root@openeuler-riscv64 ~]# + expect
spawn ssh -2 [email protected]
[email protected]'s password:
Last login: Wed Apr 26 14:17:54 2023 from 10.198.114.3
Welcome to 6.1.8-3.oe2303.riscv64
System information as of time: Wed Apr 26 02:19:40 PM CST 2023
System load: [0;33;40m1.39[0m
Processes: 111
Memory used: 2.8%
Swap used: 0.0%
Usage On: 26%
IP address: 10.198.114.6
IP address: 10.0.2.15
Users online: 1
[root@openeuler-riscv64 ~]# + P_SSH_CMD --node 2 --cmd 'test -f ca.crt -a -f server.crt -a -f server.key'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'test -f ca.crt -a -f server.crt -a -f server.key'
+ CHECK_RESULT 1
+ actual_result=1
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 1 ']'
+ '[' 0 -eq 0 ']'
+ test 1x '!=' 0x
+ test -n ''
+ (( exec_result++ ))
+ LOG_ERROR 'oe_test_openvpn.sh line 173'
+ message='oe_test_openvpn.sh line 173'
+ python3 /root/mugen/libs/locallibs/mugen_log.py --level error --message 'oe_test_openvpn.sh line 173'
Wed Apr 26 14:21:07 2023 - ERROR - oe_test_openvpn.sh line 173
+ '[' 0 -eq 1 ']'
+ return 0
+ P_SSH_CMD --node 2 --cmd 'openssl dhparam -out dh1024.pem 1024'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'openssl dhparam -out dh1024.pem 1024'
+ SLEEP_WAIT 15
+ wait_time=15
+ cmd=
+ mode=1
+ python3 /root/mugen/libs/locallibs/sleep_wait.py --time 15 --cmd '' --mode 1
+ P_SSH_CMD --node 2 --cmd 'test -f dh1024.pem'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'test -f dh1024.pem'
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
+ P_SSH_CMD --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --tls-server --dh dh1024.pem --ca ca.crt --cert server.crt --key server.key --reneg-sec 60 --verb 5 >/dev/null 2>&1 &'
+ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'nohup openvpn --remote 10.198.114.3 --dev tun1 --ifconfig 10.4.0.2 10.4.0.1 --tls-server --dh dh1024.pem --ca ca.crt --cert server.crt --key server.key --reneg-sec 60 --verb 5 >/dev/null 2>&1 &'
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0
+ '[' -z 0 ']'
+ '[' 0 -eq 0 ']'
+ test 0x '!=' 0x
+ return 0
++ P_SSH_CMD --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ python3 /root/mugen/libs/locallibs/ssh_cmd.py --node 2 --cmd 'pgrep -f '\''openvpn --remote'\'''
++ tail -n 1
++ awk -F '\r' '{print $1}'
+ remote_pid=
+ CHECK_RESULT 0
+ actual_result=0
+ expect_result=0
+ mode=0
+ error_log=
+ exit_mode=0