снова в бою mpd в качестве vpn сервера

Проблемы установки, настройки и работы Правильной Операционной Системы

Модератор: terminus

Правила форума
Убедительная просьба юзать теги [cоde] при оформлении листингов.
Сообщения не оформленные должным образом имеют все шансы быть незамеченными.
Аватара пользователя
Notaky
мл. сержант
Сообщения: 80
Зарегистрирован: 2006-09-13 19:23:46
Контактная информация:

снова в бою mpd в качестве vpn сервера

Непрочитанное сообщение Notaky » 2006-12-12 22:51:13

Доброго времени суток...
Пытаюсь сделать VPN сервер для локалки..
Использую в качестве сервера mpd4-4.0b4...
использовал статью m`a`x 'a и еще пару источников в качестве точки отправления..

Код: Выделить всё

Id Refs Address    Size     Name
 1   23 0xc0400000 433f9c   kernel
 2   16 0xc0834000 568dc    acpi.ko
 3    1 0xc1d8d000 15000    linux.ko
 4    1 0xc2315000 1b000    smbfs.ko
 5    2 0xc2330000 3000     libiconv.ko
 6    2 0xc2333000 3000     libmchain.ko
 7   12 0xc40c8000 a000     netgraph.ko
 8    1 0xc3656000 3000     ng_iface.ko
 9    1 0xc40b9000 6000     ng_ppp.ko
10    1 0xc3fde000 4000     ng_socket.ko
11    1 0xc40d2000 5000     ng_pppoe.ko
12    1 0xc408d000 4000     ng_vjc.ko
13    1 0xc3ff1000 3000     ng_ether.ko
14    1 0xc35dc000 2000     ng_tcpmss.ko
15    1 0xc40a2000 4000     ng_bpf.ko
16    1 0xc406d000 3000     ng_mppc.ko
17    1 0xc35fe000 2000     rc4.ko
18    1 0xc40db000 4000     ng_pptpgre.ko
19    1 0xc40df000 4000     ng_ksocket.ko
mpd.conf

Код: Выделить всё

startup:
        set console port 5005
        set console ip 127.0.0.1
        set console user admin  admin
        set console open

default:
        load pptp1

pptp1:
        new -i ng0 pptp1 pptp1
        set ipcp ranges 192.168.0.1/32 192.168.1.20/32
        load cli
cli:
        set iface disable on-demand
        set iface enable proxy-arp
        set iface idle 1800
        set iface enable tcpmssfix
        set bundle enable multilink
        set link yes acfcomp protocomp
        set link no pap chap
        set link enable chap
        set link mtu 1460
        set iface mtu 1500
        set link keep-alive 10 60
        set ipcp yes vjcomp
        set ipcp dns 192.168.0.1
        set bundle enable compression
        set ccp yes mppc
        set ccp yes mpp-e40
        set ccp yes mpp-e128
        set ccp yes mpp-stateless
mpd.links

Код: Выделить всё

pptp1:
        set link type pptp
        set pptp self 217.20.183.157
        set pptp enable incoming
        set pptp disable originate
mpd.secret

Код: Выделить всё

admin   "admin" *

mpd.log

Код: Выделить всё

Dec 12 21:41:40 gw mpd: mpd: pid 83048, version 4.0b5 (root@gw.sg-ua.com 19:05 22-Nov-2006)
Dec 12 21:41:40 gw mpd: CONSOLE: listening on 127.0.0.1 5005
Dec 12 21:41:40 gw mpd: [pptp1] ppp node is "mpd83048-pptp1"
Dec 12 21:41:40 gw mpd: tcpmss node is "mpd83048-mss"
Dec 12 21:41:40 gw mpd: [pptp1] using interface ng0
Dec 12 21:41:50 gw mpd: mpd: PPTP connection from 192.168.0.7 2523
Dec 12 21:41:50 gw mpd: pptp0: attached to connection with 192.168.0.7 2523
Dec 12 21:41:50 gw mpd: [pptp1] opening link "pptp1"...
Dec 12 21:41:50 gw mpd: [pptp1] link: OPEN event
Dec 12 21:41:50 gw mpd: [pptp1] LCP: Open event
Dec 12 21:41:50 gw mpd: [pptp1] LCP: state change Initial --> Starting
Dec 12 21:41:50 gw mpd: [pptp1] LCP: LayerStart
Dec 12 21:41:50 gw mpd: [pptp1] attaching to peer's outgoing call
Dec 12 21:41:50 gw mpd: [pptp1] link: UP event
Dec 12 21:41:50 gw mpd: [pptp1] link: origination is remote
Dec 12 21:41:50 gw mpd: [pptp1] LCP: Up event
Dec 12 21:41:50 gw mpd: [pptp1] LCP: state change Starting --> Req-Sent
Dec 12 21:41:50 gw mpd: [pptp1] LCP: SendConfigReq #1
Dec 12 21:41:50 gw mpd:  ACFCOMP
Dec 12 21:41:50 gw mpd:  PROTOCOMP
Dec 12 21:41:50 gw mpd:  MRU 1500
Dec 12 21:41:50 gw mpd:  MAGICNUM 19f86670
Dec 12 21:41:50 gw mpd:  AUTHPROTO CHAP MSOFTv2
Dec 12 21:41:50 gw mpd:  MP MRRU 1600
Dec 12 21:41:50 gw mpd:  MP SHORTSEQ
Dec 12 21:41:50 gw mpd:  ENDPOINTDISC [802.1] 00 0d 88 6c e6 d2
Dec 12 21:41:50 gw mpd: pptp0-0: ignoring SetLinkInfo
Dec 12 21:41:50 gw mpd: [pptp1] LCP: rec'd Configure Request #0 link 0 (Req-Sent)
Dec 12 21:41:50 gw mpd:  MRU 1400
Dec 12 21:41:50 gw mpd:  MAGICNUM 4b532c23
Dec 12 21:41:50 gw mpd:  PROTOCOMP
Dec 12 21:41:50 gw mpd:  ACFCOMP
Dec 12 21:41:50 gw mpd:  CALLBACK
Dec 12 21:41:50 gw mpd:    Not supported
Dec 12 21:41:50 gw mpd: [pptp1] LCP: SendConfigRej #0
Dec 12 21:41:50 gw mpd:  CALLBACK
Dec 12 21:41:50 gw mpd: [pptp1] LCP: rec'd Configure Request #1 link 0 (Req-Sent)
Dec 12 21:41:50 gw mpd:  MRU 1400
Dec 12 21:41:50 gw mpd:  MAGICNUM 4b532c23
Dec 12 21:41:50 gw mpd:  PROTOCOMP
Dec 12 21:41:50 gw mpd:  ACFCOMP
Dec 12 21:41:50 gw mpd: [pptp1] LCP: SendConfigAck #1
Dec 12 21:41:50 gw mpd:  MRU 1400
Dec 12 21:41:50 gw mpd:  MAGICNUM 4b532c23
Dec 12 21:41:50 gw mpd:  PROTOCOMP
Dec 12 21:41:50 gw mpd:  ACFCOMP
Dec 12 21:41:50 gw mpd: [pptp1] LCP: state change Req-Sent --> Ack-Sent
Dec 12 21:41:52 gw mpd: [pptp1] LCP: SendConfigReq #2
Dec 12 21:41:52 gw mpd:  ACFCOMP
Dec 12 21:41:52 gw mpd:  PROTOCOMP
Dec 12 21:41:52 gw mpd:  MRU 1500
Dec 12 21:41:52 gw mpd:  MAGICNUM 19f86670
Dec 12 21:41:52 gw mpd:  AUTHPROTO CHAP MSOFTv2
Dec 12 21:41:52 gw mpd:  MP MRRU 1600
Dec 12 21:41:52 gw mpd:  MP SHORTSEQ
Dec 12 21:41:52 gw mpd:  ENDPOINTDISC [802.1] 00 0d 88 6c e6 d2
Dec 12 21:41:52 gw mpd: [pptp1] LCP: rec'd Configure Reject #2 link 0 (Ack-Sent)
Dec 12 21:41:52 gw mpd:  MP MRRU 1600
Dec 12 21:41:52 gw mpd:  MP SHORTSEQ
Dec 12 21:41:52 gw mpd:  ENDPOINTDISC [802.1] 00 0d 88 6c e6 d2
Dec 12 21:41:52 gw mpd: [pptp1] LCP: SendConfigReq #3
Dec 12 21:41:52 gw mpd:  ACFCOMP
Dec 12 21:41:52 gw mpd:  PROTOCOMP
Dec 12 21:41:52 gw mpd:  MRU 1500
Dec 12 21:41:52 gw mpd:  MAGICNUM 19f86670
Dec 12 21:41:52 gw mpd:  AUTHPROTO CHAP MSOFTv2
Dec 12 21:41:52 gw mpd: [pptp1] LCP: rec'd Configure Ack #3 link 0 (Ack-Sent)
Dec 12 21:41:52 gw mpd:  ACFCOMP
Dec 12 21:41:52 gw mpd:  PROTOCOMP
Dec 12 21:41:52 gw mpd:  MRU 1500
Dec 12 21:41:52 gw mpd:  MAGICNUM 19f86670
Dec 12 21:41:52 gw mpd:  AUTHPROTO CHAP MSOFTv2
Dec 12 21:41:52 gw mpd: [pptp1] LCP: state change Ack-Sent --> Opened
Dec 12 21:41:52 gw mpd: [pptp1] LCP: auth: peer wants nothing, I want CHAP
Dec 12 21:41:52 gw mpd: [pptp1] CHAP: sending CHALLENGE len:17
Dec 12 21:41:52 gw mpd: [pptp1] LCP: LayerUp
Dec 12 21:41:52 gw mpd: pptp0-0: ignoring SetLinkInfo
Dec 12 21:41:52 gw mpd: [pptp1] LCP: rec'd Ident #2 link 0 (Opened)
Dec 12 21:41:52 gw mpd:  MESG: MSRASV5.10
Dec 12 21:41:52 gw mpd: [pptp1] LCP: rec'd Ident #3 link 0 (Opened)
Dec 12 21:41:52 gw mpd:  MESG: MSRAS-0-ADMIN
Dec 12 21:41:52 gw mpd: [pptp1] CHAP: rec'd RESPONSE #1
Dec 12 21:41:52 gw mpd:  Name: "admin"
Dec 12 21:41:52 gw mpd: [pptp1] AUTH: Auth-Thread started
Dec 12 21:41:52 gw mpd: [pptp1] AUTH: Trying secret file: mpd.secret
Dec 12 21:41:52 gw mpd:  Peer name: "admin"
Dec 12 21:41:52 gw mpd: [pptp1] AUTH: Auth-Thread finished normally
Dec 12 21:41:52 gw mpd: [pptp1] CHAP: ChapInputFinish: status undefined
Dec 12 21:41:52 gw mpd:  Response is valid
Dec 12 21:41:52 gw mpd: [pptp1] CHAP: sending SUCCESS len:42
Dec 12 21:41:52 gw mpd: [pptp1] LCP: authorization successful
Dec 12 21:41:52 gw mpd: [pptp1] Bundle up: 1 link, total bandwidth 64000 bps
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: Open event
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: state change Initial --> Starting
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: LayerStart
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Open event
Dec 12 21:41:52 gw mpd: [pptp1] CCP: state change Initial --> Starting
Dec 12 21:41:52 gw mpd: [pptp1] CCP: LayerStart
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: Up event
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: state change Starting --> Req-Sent
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: SendConfigReq #1
Dec 12 21:41:52 gw mpd:  IPADDR 192.168.0.1
Dec 12 21:41:52 gw mpd:  COMPPROTO VJCOMP, 16 comp. channels, no comp-cid
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Up event
Dec 12 21:41:52 gw mpd: [pptp1] CCP: state change Starting --> Req-Sent
Dec 12 21:41:52 gw mpd: [pptp1] CCP: SendConfigReq #1
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Checking whether 40 bits are enabled -> yes
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Checking whether 56 bits are enabled -> no
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Checking whether 128 bits are enabled -> yes
Dec 12 21:41:52 gw mpd:  MPPC
Dec 12 21:41:52 gw mpd:    0x01000060: MPPE, 40 bit, 128 bit, stateless
Dec 12 21:41:52 gw mpd: pptp0-0: ignoring SetLinkInfo
Dec 12 21:41:52 gw mpd: [pptp1] LCP: rec'd Terminate Request #4 link 0 (Opened)
Dec 12 21:41:52 gw mpd: [pptp1] LCP: state change Opened --> Stopping
Dec 12 21:41:52 gw mpd: [pptp1] AUTH: Accounting data for user admin: 2 seconds, 221 octets in, 249 octets out
Dec 12 21:41:52 gw mpd: [pptp1] AUTH: Cleanup
Dec 12 21:41:52 gw mpd: [pptp1] Bundle up: 0 links, total bandwidth 9600 bps
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: Down event
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: state change Req-Sent --> Starting
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Down event
Dec 12 21:41:52 gw mpd: [pptp1] CCP: state change Req-Sent --> Starting
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: Close event
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: state change Starting --> Initial
Dec 12 21:41:52 gw mpd: [pptp1] IPCP: LayerFinish
Dec 12 21:41:52 gw mpd: [pptp1] No NCPs left. Closing links...
Dec 12 21:41:52 gw mpd: [pptp1] closing link "pptp1"...
Dec 12 21:41:52 gw mpd: [pptp1] CCP: Close event
Dec 12 21:41:52 gw mpd: [pptp1] CCP: state change Starting --> Initial
Dec 12 21:41:52 gw mpd: [pptp1] CCP: LayerFinish
Dec 12 21:41:52 gw mpd: [pptp1] Last link has gone and no noretry option, will reopen in 3 seconds
Dec 12 21:41:52 gw mpd: [pptp1] LCP: SendTerminateAck #4
Dec 12 21:41:52 gw mpd: [pptp1] LCP: LayerDown
Dec 12 21:41:52 gw mpd: [pptp1] link: CLOSE event
Dec 12 21:41:52 gw mpd: [pptp1] LCP: Close event
Dec 12 21:41:52 gw mpd: [pptp1] LCP: state change Stopping --> Closing
Dec 12 21:41:53 gw mpd: pptp0-0: call cleared by peer
Dec 12 21:41:53 gw mpd: pptp0-0: killing channel
Dec 12 21:41:53 gw mpd: [pptp1] PPTP call terminated
Dec 12 21:41:53 gw mpd: [pptp1] IFACE: Close event
Dec 12 21:41:53 gw mpd: [pptp1] IFACE: Close event
Dec 12 21:41:53 gw mpd: pptp0: closing connection with 192.168.0.7 2523
Dec 12 21:41:53 gw mpd: [pptp1] link: DOWN event
Dec 12 21:41:53 gw mpd: [pptp1] LCP: Down event
Dec 12 21:41:53 gw mpd: [pptp1] LCP: LayerFinish
Dec 12 21:41:53 gw mpd: [pptp1] LCP: state change Closing --> Initial
Dec 12 21:41:53 gw mpd: pptp0: killing connection with 192.168.0.7 2523
Dec 12 21:41:55 gw mpd: [pptp1] Last link has gone and no noretry option, reopening in 3 seconds
Dec 12 21:41:58 gw mpd: [pptp1] opening link "pptp1"...
Dec 12 21:41:58 gw mpd: [pptp1] link: OPEN event
Dec 12 21:41:58 gw mpd: [pptp1] LCP: Open event
Dec 12 21:41:58 gw mpd: [pptp1] LCP: state change Initial --> Starting
Dec 12 21:41:58 gw mpd: [pptp1] LCP: LayerStart
Dec 12 21:41:58 gw mpd: [pptp1] pausing 2 seconds before open
Dec 12 21:42:00 gw mpd: [pptp1] pausing 1 seconds before open
Dec 12 21:42:01 gw mpd: [pptp1] pptp originate option is not enabled
Dec 12 21:42:01 gw mpd: [pptp1] link: DOWN event
Dec 12 21:42:01 gw mpd: [pptp1] LCP: Down event
Dec 12 21:42:01 gw mpd: [pptp1] pausing 7 seconds before open
Конекчусь с винтовой машинки, ничего неизменяя в настройках.
поидеи ошибка гдето на поверхности просто найти немогу.

[21:46] gw# uname -r
6.0-RELEASE

Уточню
ошибка 778: Невозможно проверить идентичность сервера :? ,
такая же ошибка при конекте с наружи.
Буду благодарен за помощь.

Хостинговая компания Host-Food.ru
Хостинг HostFood.ru
 

Услуги хостинговой компании Host-Food.ru

Хостинг HostFood.ru

Тарифы на хостинг в России, от 12 рублей: https://www.host-food.ru/tariffs/hosting/
Тарифы на виртуальные сервера (VPS/VDS/KVM) в РФ, от 189 руб.: https://www.host-food.ru/tariffs/virtualny-server-vps/
Выделенные сервера, Россия, Москва, от 2460 рублей (8 CPU, 8Gb RAM, 2x500Gb HDD, RAID 3ware 9750):
https://www.host-food.ru/tariffs/vydelennyi-server-ds/
Недорогие домены в популярных зонах: https://www.host-food.ru/domains/

Аватара пользователя
Notaky
мл. сержант
Сообщения: 80
Зарегистрирован: 2006-09-13 19:23:46
Контактная информация:

Непрочитанное сообщение Notaky » 2006-12-13 21:29:42

Что никуого нету никаких идей?

Аватара пользователя
Notaky
мл. сержант
Сообщения: 80
Зарегистрирован: 2006-09-13 19:23:46
Контактная информация:

Непрочитанное сообщение Notaky » 2006-12-14 16:39:57

странная всеже вещь mpd4, толь у меня мозгов на него нехватило....но mpd3 все завелось и работает. :shock:

wel
сержант
Сообщения: 170
Зарегистрирован: 2007-02-27 11:59:41

Непрочитанное сообщение wel » 2007-02-27 12:04:46

Notaky писал(а):странная всеже вещь mpd4, толь у меня мозгов на него нехватило....но mpd3 все завелось и работает. :shock:
Вот-с скрипт - пока никто н еперепечатал и не сказал что то Он Его придумал...
ip1=192 ip2=168 ip3=11 ip4=2 - начальный ИП
maxlink=700 - сколько у МПД4 будет линков...
Для mpd3 - надо другие директивы включать иначе Он не заработает!!!Так же и с МПД4- в Инете дохрина всяких примеров настройки но Они все под mpd3 в основном

Код: Выделить всё

#!/bin/sh
ip4=2
ip3=11
ip2=168
ip1=192
serverip="192.168.11.1/32"
maxlink=700
rm mpd.links
echo "startup:
    set console port 5005
    set console ip 127.0.0.1
    set console user mpd password
    set console open
default:	
">mpd.conf
lname=0
for num in `jot $maxlink 10 20`
do
lname=`expr $lname + 1`

echo "        load pptp$lname">>mpd.conf
echo "pptp$lname:
        set link type pptp">>mpd.links
	

done

lname=0
for num in `jot $maxlink 10 20`
do

if [ "$ip4" -ge 254 ] 
then
ip3=`expr $ip3 + 1`
ip4=1
fi
lname=`expr $lname + 1`
ipall="$ip1.$ip2.$ip3.$ip4"


echo "pptp$lname:
        new -i ng$lname pptp$lname pptp$lname
	set ipcp ranges  $serverip  $ipall/32
	load pptp_standart">>mpd.conf
ip4=`expr $ip4 + 1`


done

echo "
pptp_standart:
    set pptp disable windowing
    set iface route default
    set iface disable on-demand
    set iface enable tcpmssfix
    set bundle disable multilink
    set link yes acfcomp protocomp
    set iface up-script \"/usr/local/etc/mpd4/link-up\"
    set iface down-script \"/usr/local/etc/mpd4/link-down\"
    set link no pap chap
    set link enable chap
    set link keep-alive 10 75
    set ipcp yes vjcomp
    set ipcp dns 10.11.25.1
#    set link mtu 1460
#    set link mru 1460
    set iface enable proxy-arp
    set bundle enable compression
    set ccp yes mppc
    set ccp yes mpp-e40
    set ccp yes mpp-e128
    set ccp yes mpp-stateless
    set pptp enable incoming
    set pptp disable originate
#   set radius config /opt/radius.conf
    set radius me 127.0.0.1
    set radius retries 2
    set radius server 127.0.0.1 password 1812 1813
    set radius timeout 5
    set auth acct-update 300
    set auth enable radius-auth
    set auth enable radius-acct ">>mpd.conf
welcome(C)