Size: a a a

2018 January 31

MG

Marcelo Gondim in Accel-PPP
Hi Glauber, my accel-ppp.lua:
источник

MG

Marcelo Gondim in Accel-PPP
function username(pkt)
return pkt:agent_circuit_id('')
end
источник

MG

Marcelo Gondim in Accel-PPP
Work with ipoe + dhcp option82 + circuit-id in GPON  :)
источник

G

Glauber in Accel-PPP
Marcelo, work nice here too, but i need use circuit-id in login and password .
источник

G

Glauber in Accel-PPP
on ixc, i have a option dhcp82 , he dont create login and password ... in this option ixc create a entry with only circuit-id, like that.
источник

G

Glauber in Accel-PPP
источник

G

Glauber in Accel-PPP
i looking for a way to authenticate using only this entry.
источник

MG

Marcelo Gondim in Accel-PPP
Ummm in my case circuit-id is my login and password in radius
источник

G

Glauber in Accel-PPP
nice, that way work like a charm!
источник

MG

Marcelo Gondim in Accel-PPP
источник

G

Glauber in Accel-PPP
thinking here... maybe i can try disable login at accel-ppp.conf and use lua to get circuit-id as password.
источник

G

Glauber in Accel-PPP
would work ?
источник

MG

Marcelo Gondim in Accel-PPP
yep :)
источник

MG

Marcelo Gondim in Accel-PPP
[ipoe]
username=lua:username
lua-file=/etc/accel-ppp.lua
источник

MG

Marcelo Gondim in Accel-PPP
(root@accel02)[~]# cat /etc/accel-ppp.lua
function username(pkt)
return pkt:agent_circuit_id('')
end
источник

D

Dmytro in Accel-PPP
GPON OLT sends data in ASCII format, so no conversion is necessary. But commutators send it in binary type. I use two separate function for GPON and ethernet commutators:
function gpon(pkt)

       return pkt:agent_circuit_id()

end


function switch(pkt)

local hex_circuit_id=''
local fmt_circuit_id=''
local hex_remote_id=''
local fmt_remote_id=''


len_circuit=string.len(pkt:agent_circuit_id())+1
len_remote=string.len(pkt:agent_remote_id())+1


   for i = 1, len_circuit do
       hex_circuit_id=hex_circuit_id..'%02x'
       fmt_circuit_id=fmt_circuit_id..'b'
   end


   for j = 1, len_remote do
       hex_remote_id=hex_remote_id..'%02x'
       fmt_remote_id=fmt_remote_id..'b'
   end


local circuit_id=string.format(hex_circuit_id, string.unpack(pkt:agent_circuit_id(),fmt_circuit_id))
local remote_id=string.format(hex_remote_id, string.unpack(pkt:agent_remote_id(),fmt_remote_id))
return string.sub(circuit_id,3)..'-'..string.sub(remote_id,3)
end
источник

D

Dmytro in Accel-PPP
In config accel-pppd:
[..skip..]
interface=enp2s0f0.761,username=lua:gpon
interface=enp2s0f0.762,username=lua:switch
interface=enp2s0f0.601,username=lua:gpon
[..skip..]
источник

VG

Vladislav Grishenko in Accel-PPP
Alex Yakovenko
Здравствуйте,
Пробую приготовить l2tp+ipsec сервер.
Accel-ppp, strongswan, маршруты выдает dnsmasq.
Клиенты - mac, windows, linux.
Все три ОС подключаются, но маршруты получают только mac/ios.
В windows "use default gateway on remote network" не отмечена, "disable class based route addition" не выключена.
Не подскажете в куда смотреть ?
в dnsmasq. для dhcp слушать нужно на адресе, не на интерфейсе
источник

UC

Uesley Correa in Accel-PPP
Dmytro
In config accel-pppd:
[..skip..]
interface=enp2s0f0.761,username=lua:gpon
interface=enp2s0f0.762,username=lua:switch
interface=enp2s0f0.601,username=lua:gpon
[..skip..]
wowww!
источник

UC

Uesley Correa in Accel-PPP
username for interface?
источник