Radsec issues after 7.15 upgrade

7.20 Beta 2 - RadSec is still broken. Multiple tickets were sent to support, none returned.

when I select radsec my router becomes unresponsive and watchdog reboots it
02 system,error,critical router was rebooted without proper shutdown by watchdog timer
then I have short time to disable it before it happens again

ros 7.19.1 on RB3011UiAS-RM

I just got notified that the issue is fixed and slated to be released in an upcoming release. Hope we don’t have to wait much longer..

Can confirm after 7.19.3 radsec seems to be working for me - one unique thing about mikrotik’s implementation is they actually do name validation on the radius server, so its important that the cert includes the IP in the SAN field at very least.

I can also confirm it works on 7.19.3 but
I have also noticed high cpu usage on mikrotik router by radius process after ssh login,
checked on multiple various mikrotik routers, radius process occupies one cpu core to 100%,
other cpu cores seem unaffected

also on latest 6.49.18 does not work and I have about 3k devices in network on ros 6.x :frowning:

on 6.49.19 watchdog timer reboot loop

please fix

It seems we are able to get high SSL load after radsec session closure. We will see what we can do about it.

tested on 7.20 just in case ( I know there's nothing in changelog about radsec but wanted to check anyway) issue is still present :slight_smile:

Any updates? :frowning:

v7.20.6 here, i got the issue and it frustate me that there is no solutions to this problem!

I was able to trigger a RADSEC request — a certificate for the RADIUS server is mandatory when using RADSEC. Without cert - RouterOs not even trying to send radius requests. I am using test self-signed certificates, but I was not able to authenticate because RouterOS seems to refuse to accept the server certificate. The connection on the RADIUS server side is aborted with this debug message.

(0) (TLS) RADIUS/TLS - recv TLS 1.2 Alert, fatal bad_certificate
Debug: (0) (TLS) RADIUS/TLS - The client is informing us that it believes the server certificate is invalid or malformed.
ERROR: (0) (TLS) RADIUS/TLS - Alert read:fatal:bad certificate
Debug: (0) (TLS) RADIUS/TLS - Server : Need to read more data: error
ERROR: (0) (TLS) Failed reading from OpenSSL: ../ssl/record/rec_layer_s3.c[1599]:error:0A000412:SSL routines::sslv3 alert bad certificate
Debug: (0) (TLS) RADIUS/TLS - In Handshake Phase
Debug: (0) (TLS) RADIUS/TLS - Application data.

I’ve tried PEM file with cert + key, PEM files with cert + ca.cert + key, p12 file - not working.

With log topics debug, radius, and debug,certificate enabled and stored in memory, I don’t see any error messages in the log. Only this

start CRL update

Maybe someone from MikroTik can explain what is required. Do I need to use globally trusted cert?

Figured it out — found in the thread above that RouterOS checks the server certificate CN/SAN. The default script provided by the FreeRADIUS 3.2 branch

generates the server certificate without it. Uncomment the line to include the v3 extension and provide it in the alt names.

domain or IP, whichever is relevant for you. After that, I was able to establish the RADSEC connection.

P.S.
Debug logs for RouterOS are useless. Please improve them. Other vendors’ implementations do not check CN/SAN; I mean, checking the certificate CN/SAN is important; I support it, but we need documentation about it, or at least logs that point in the direction of how to fix it. I was able to connect using the default server certificate with devices from other vendors.

In RouterOS, I used a PKCS#12 certificate that includes client.crt, client.key, and ca.crt.

wow
7.22beta5
*) radius - fixed RadSec SSL CPU usage increase on closed connections;

ok, using 7.22.1 on 2500+ devices, all with enabled radsec, same radius configuration, same script which generates certificates on server, everything same…

but, i have 2 devices (both are 3011) which refuse to work, hang on TLS handshake and i got handshake timeout…

only difference I was able to spot is this:
on devices which work no problem (certificate/print detail) I have: serial-number uppercase and in issuer field ST=myvalue

on those 2 devices that don’t work i have: serial-number lowercase and in issuer field just S=myvalue (missing T)

tried package reinstall, cert regeneration, rebooting …

hm, maybe this was not exactly radsec problem, this helped

/ip firewall mangle
add chain=output action=change-mss new-mss=1300 passthrough=yes \
protocol=tcp tcp-flags=syn tcp-mss=!0-1300 \
dst-port=2083 comment="Clamp RadSec MSS to 1300"

seems we have mtu degradation on path and maybe even silent drops of packets which prevent tls handshake to finish

Adding to this since it's still the case on 7.26. RouterOS checks the RadSec server cert against the IP set in /radius, and the address field only takes an IP (per the 7.26 RADIUS docs). Reissuing the server cert w/ the IP in SAN works when you run the RADIUS server yourself, but not w/ an outside provider whose cert only lists DNS names.

My case: Passpoint carrier offload for Helium on a hAP be lite. Helium's RadSec server is radius-bf.wifi.hellohelium.com and its cert has DNS names only, so native RadSec fails w/ "ssl: name verification failed". Helium's network has over 50K devices serving over 1.5M people phone connectivity every day, and every MikroTik AP on it needs a separate box running radsecproxy as a relay.

RFC 6614 (section 2.3) checks the cert against the configured server name, and RFC 7585 dynamic discovery (used by eduroam and OpenRoaming) finds servers through DNS. Cisco IOS XE (tls match-server-identity) and Juniper (tls-peer-name) let you set the expected name.

Simple fix: allow a hostname as the RadSec server address, or add a separate expected server name setting used for the cert check and SNI. That would also cover the SNI case here: Problem with Radius Radsec with SNI

Any update from MikroTik on this? I've filed it w/ support too.

I also have issues with Radsec. What if you have two servers? One for authentication and one for accounting.

I could never get that to work.

Enable RADIUS Single Sign-On SSO

https://www.watchguard.com/help/docs/help-center/en-US/Content/en-US/Fireware/authentication/rsso_enable.html

Watchguard to ROS