SIP 전화기의 OpenVPN 사용 및 인증서 생성 설명

모듈 소개

개요

가상 사설망 VPN(virtual private network)은 공용 네트워크 위에 구축되는 안전한 네트워크 연결입니다. 일반적인 네트워크 연결과 다른 점은 전용 터널링 프로토콜을 사용하여 데이터 암호화, 무결성 검사, 사용자 인증을 구현한다는 것입니다. 이를 통해 전송 중인 정보가 엿보이거나, 변조되거나, 복사되는 것을 방지할 수 있습니다. 네트워크 연결의 보안성 측면에서 보면 공용 네트워크 위에 전용 회선 네트워크를 구축하는 것과 유사합니다. 다만 이 전용 회선은 물리적인 것이 아니라 논리적인 것이므로 가상 사설망이라고 부릅니다. VPN 시스템은 VPN 서버, VPN 클라이언트, 터널로 구성됩니다. 인터넷을 이용한 전송은 전용 회선을 임대하는 것보다 비용이 매우 낮기 때문에, VPN은 기업이 인터넷을 통해 사적인 기밀 정보를 안전하고 경제적으로 전송할 수 있게 합니다.
여기서는 OpenVPN을 이용한 VPN 설정을 소개합니다. OpenVPN은 오픈 소스 기반의 서드파티 가상 사설망 설정 도구이며, 기존 장비를 활용하여 VPN 애플리케이션 게이트웨이를 구축할 수 있습니다.

서버 설치 및 설정

OpenVPN은 오픈 소스 기반의 서드파티 가상 사설망 설정 도구이며, 기존 장비를 활용하여 VPN 애플리케이션 게이트웨이를 구축할 수 있습니다. 아래에서는 Ubuntu와 Windows 운영 체제에서 서버를 배포하고 설정하는 방법을 각각 설명합니다.

Ubuntu에서 OpenVPN 서버 구축

2.1.1 OpenVPN 서버 설치
Ubuntu에서 다음 명령을 입력합니다:
sudo apt-get -y install openvpn libssl-dev openssl
sudo apt-get -y install easy-rsa
2.1.2 인증서 제작
다음 단계에 따라 명령을 실행하여 OpenVPN이 정상적으로 동작하는 데 필요한 인증서 초기 설정을 생성합니다:
sudo mkdir /etc/openvpn/easy-rsa/
sudo cp -r /usr/share/easy-rsa/* /etc/openvpn/easy-rsa/
sudo su
sudo vi /etc/openvpn/easy-rsa/vars
----->필요에 따라 인증서 설정을 다음과 같이 수정할 수 있습니다:
export KEY_COUNTRY=”CN”
export KEY_PROVINCE=”BJ”
export KEY_CITY=”BeiJing”
export KEY_ORG=”fanvil”
export KEY_EMAIL=”fanvil@fanvil.com”
export KEY_OU=”fanvil”
export KEY_NAME=”server”
vars 실행:    source vars
처음 실행하는 경우 모두 정리:    ./clean-all
CA 인증서 생성:    ./build-ca
서버 인증서 생성:    ./build-key-server server
클라이언트 인증서 생성:    ./build-key client
동적 키 라이브러리 생성.    ./build-dh

서버 시작

서버 환경을 설정하고 해당 인증서 설정 파일을 지정된 디렉터리에 넣습니다:
cp keys/ca.crt /etc/openvpn/
cp keys/server.crt keys/server.key keys/dh2048.pem /etc/openvpn
mv /etc/openvpn/dh2048.pem /etc/openvpn/dh1024.pem
cp keys/client.key keys/client.crt   /etc/openvpn/
cp /usr/share/doc/openvpn/examples/sample-config-files/server.conf.gz /etc/openvpn/
cd /etc/openvpn
gzip -d server.conf.gz
cp /usr/share/doc/openvpn/examples/sample-config-files/client.conf /etc/openvpn/
서버 시작:
/etc/init.d/openvpn restart

Windows에서 OpenVPN 서버 구축

2.3.1 OpenVPN 서버 설치
온라인에서 Windows 버전 OpenVPN 소프트웨어를 검색하여 다운로드합니다. 이 구축 예시는 OpenVPN GUI를 사용합니다. 다운로드한 소프트웨어를 더블 클릭하여 기본 설정으로 설치하고, easy-rsa 구성 요소가 설치되도록 선택해야 합니다. 기본 경로는 C:\Program Files\OpenVPN입니다.
2.3.2 인증서 제작
작업을 수행하기 전에 먼저 초기화 작업을 진행합니다:
자신의 환경에 맞게 C:\Program Files\OPENVPN\easy-rsa\vars.bat.sample의 다음 부분을 수정하십시오:
set HOME=C:\Program Files\OPENVPN\easy-rsa
set KEY_COUNTRY=CN    #(국가)
set KEY_PROVINCE=BEIJING    #(성/지역)
set KEY_CITY= BEIJING    #(도시)
set KEY_ORG=WINLINE    #(조직)
set KEY_EMAIL=admin@winline.com.cn    #(이메일 주소)
위에서 #로 시작하는 내용은 주석입니다. 파일에 쓰지 마십시오.
관리자 권한으로 cmd를 열어 DOS에 들어간 후, 다음 명령을 실행하여
openvpn\easy-rsa 디렉터리로 이동합니다:
        init-config
        vars
        clean-all
루트 인증서 생성:    build-ca(기본 설정으로 생성하려면 계속 Enter를 누릅니다)
동적 키 라이브러리 생성:    build-dh
서버 인증서 생성:    build-key-server server(기본 설정으로 생성하려면 계속 Enter를 누릅니다)
클라이언트 인증서 생성:    build-key client(기본 설정으로 생성하려면 계속 Enter를 누릅니다)
2.3.3 서버 시작
생성된 모든 키는 OpenVPN\easy-rsa\keys 디렉터리에 저장됩니다.
생성된 인증서를 OpenVPN\config 디렉터리에 복사합니다.
OpenVPN\sample-config 아래의 서버 설정 파일을 OpenVPN\config 디렉터리에 복사한 후 OpenVPN 애플리케이션을 시작하면 됩니다.

서버 측 설정

OpenVPN 설치 디렉터리에서 notepad++를 사용하여 server.ovpn 또는 server.conf 파일을 엽니다. 서버 측 파일 예시는 다음과 같습니다:
port 1194 # 이 포트는 IANA가 OpenVPN에 할당한 지정 포트이며 필요에 따라 수정할 수 있습니다
proto udp # tcp도 선택할 수 있습니다
dev tun
ca ca.crt
cert server.crt
key server.key
dh dh1024.pem
server 10.8.0.0 255.255.255.0 # 가상 LAN 세그먼트 설정이며 필요에 따라 수정하십시오
ifconfig-pool-persist ipp.txt
keepalive 10 120
client-to-client
comp-lzo
max-clients 100
persist-key
persist-tun
status openvpn-status.log
verb 3
더 자세한 내용은 OpenVPN Wiki를 참고할 수 있습니다.

클라이언트 사용 및 설정

클라이언트 설정

여기서 클라이언트는 OpenVPN을 지원하는 장치를 의미합니다. 전화기가 OpenVPN 서버에 연결되도록 하려면 인증서 파일이 필요합니다.
먼저 클라이언트 설정 파일 client.ovpn 또는 client.conf를 편집해야 합니다. 클라이언트 설정 파일 예시는 다음과 같습니다:
client
dev tun
proto udp
remote 192.168.1.135 1194 # 서버 도메인/IP 및 포트
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert client.crt
key client.key comp-lzo
verb 3
서버 측 설정에 맞춰 관련 설정을 수정할 수 있습니다.
그다음 앞서 만든 클라이언트 파일 ca.crt, client.crt, client.key를 내보내 전화기 업그레이드 시 사용합니다.

전화기에서 OpenVPN 사용

전화기 웹 페이지에 로그인한 뒤 순서대로 네트워크->VPN을 클릭합니다. OpenVPN 파일 항목에서 client.ovpn, client.key, client.crt, ca.crt를 하나씩 업로드합니다. 업로드가 완료되면 OpenVPN 파일 항목에 업로드된 인증서 파일 크기가 표시되며, 아래와 같습니다:
OpenVPN 파일 업로드VPN 설정 페이지를 열고 VPN 모드에서 Open VPN을 선택한 다음 VPN을 활성화하고 제출 버튼을 클릭합니다. 서버에 성공적으로 연결되면 VPN 페이지의 VPN 온라인 상태 항목에 획득한 IP 주소가 표시됩니다. 아래 그림과 같이 획득한 IP는 10.8.0.10입니다.
VPN 설정 화면 열기

VPN NAT 활성화

VPN NAT 활성화 화면
사용 방법:
전화기에 VPN 인증서를 가져오고 Enable VPN 및 Enable NAT를 활성화한 후, PC를 전화기의 LAN 포트에 연결합니다. PC의 게이트웨이는 전화기의 IP로 설정해야 합니다. 이때 PC는 전화기의 VPN에 접근할 수 있습니다.
PC ping10.8.0.10은 ping이 통과되고, ping www.baidu.com도 통과됩니다. 10.8.0.10은 VPN IP 주소입니다.
참고: 현재 지원 모델은 J3G/X3U/X3SG/J1P 및 X5S/X6/X7/X7C/X210/X210i입니다. 전화기 X3S/X4/X7은 현재 지원하지 않습니다.

카탈로그
고객 서비스 전화
We use cookie to improve your online experience. By continuing to browse this website, you agree to our use of cookie.

Cookies

This Cookie Policy explains how we use cookies and similar technologies when you access or use our website and related services. Please read this Policy together with our Terms and Conditions and Privacy Policy so that you understand how we collect, use, and protect information.

By continuing to access or use our Services, you acknowledge that cookies and similar technologies may be used as described in this Policy, subject to applicable law and your available choices.

Updates to This Cookie Policy

We may revise this Cookie Policy from time to time to reflect changes in legal requirements, technology, or our business practices. When we make updates, the revised version will be posted on this page and will become effective from the date of publication unless otherwise required by law.

Where required, we will provide additional notice or request your consent before applying material changes that affect your rights or choices.

What Are Cookies?

Cookies are small text files placed on your device when you visit a website or interact with certain online content. They help websites recognize your browser or device, remember your preferences, support essential functionality, and improve the overall user experience.

In this Cookie Policy, the term “cookies” also includes similar technologies such as pixels, tags, web beacons, and other tracking tools that perform comparable functions.

Why We Use Cookies

We use cookies to help our website function properly, remember user preferences, enhance website performance, understand how visitors interact with our pages, and support security, analytics, and marketing activities where permitted by law.

We use cookies to keep our website functional, secure, efficient, and more relevant to your browsing experience.

Categories of Cookies We Use

Strictly Necessary Cookies

These cookies are essential for the operation of the website and cannot be disabled in our systems where they are required to provide the service you request. They are typically set in response to actions such as setting privacy preferences, signing in, or submitting forms.

Without these cookies, certain parts of the website may not function correctly.

Functional Cookies

Functional cookies enable enhanced features and personalization, such as remembering your preferences, language settings, or previously selected options. These cookies may be set by us or by third-party providers whose services are integrated into our website.

If you disable these cookies, some services or features may not work as intended.

Performance and Analytics Cookies

These cookies help us understand how visitors use our website by collecting information such as traffic sources, page visits, navigation behavior, and general interaction patterns. In many cases, this information is aggregated and does not directly identify individual users.

We use this information to improve website performance, usability, and content relevance.

Targeting and Advertising Cookies

These cookies may be placed by our advertising or marketing partners to help deliver more relevant ads and measure the effectiveness of campaigns. They may use information about your browsing activity across different websites and services to build a profile of your interests.

These cookies generally do not store directly identifying personal information, but they may identify your browser or device.

First-Party and Third-Party Cookies

Some cookies are set directly by our website and are referred to as first-party cookies. Other cookies are set by third-party services, such as analytics providers, embedded content providers, or advertising partners, and are referred to as third-party cookies.

Third-party providers may use their own cookies in accordance with their own privacy and cookie policies.

Information Collected Through Cookies

Depending on the type of cookie used, the information collected may include browser type, device type, IP address, referring website, pages viewed, time spent on pages, clickstream behavior, and general usage patterns.

This information helps us maintain the website, improve performance, enhance security, and provide a better user experience.

Your Cookie Choices

You can control or disable cookies through your browser settings and, where available, through our cookie consent or preference management tools. Depending on your location, you may also have the right to accept or reject certain categories of cookies, especially those used for analytics, personalization, or advertising purposes.

Please note that blocking or deleting certain cookies may affect the availability, functionality, or performance of some parts of the website.

Restricting cookies may limit certain features and reduce the quality of your experience on the website.

Cookies in Mobile Applications

Where our mobile applications use cookie-like technologies, they are generally limited to those required for core functionality, security, and service delivery. Disabling these essential technologies may affect the normal operation of the application.

We do not use essential mobile application cookies to store unnecessary personal information.

How to Manage Cookies

Most web browsers allow you to manage cookies through browser settings. You can usually choose to block, delete, or receive alerts before cookies are stored. Because browser controls vary, please refer to your browser provider’s support documentation for details on how to manage cookie settings.

Contact Us

If you have any questions about this Cookie Policy or our use of cookies and similar technologies, please contact us at support@becke.cc .