Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Unable to authenticate even using radtest using freeRADIUS

    pfSense Packages
    3
    15
    7.1k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      Snailkhan
      last edited by

      after a lot of searching found this thread

      https://forum.pfsense.org/index.php?topic=86158.msg573823#msg573823

      i am quoting my reply from that quote here .
      i also faced similar issue in freeradius2 installation and somehow managed to install it as mentioned below.
      but i cannot start its service ..
      when i check system logs i see below

      Nov 23 23:06:43 root: /usr/pbi/freeradius-i386/local/etc/rc.d/radiusd: WARNING: run_rc_command: cannot run /usr/local/sbin/radiusd
      Nov 23 23:05:58 root: /usr/pbi/freeradius-i386/local/etc/rc.d/radiusd: WARNING: run_rc_command: cannot run /usr/local/sbin/radiusd
      Nov 23 23:05:32 check_reload_status: Reloading filter
      Nov 23 23:05:30 php-fpm[85699]: /pkg_mgr_install.php: Successfully installed package: freeradius2.
      Nov 23 23:05:30 check_reload_status: Syncing firewall
      Nov 23 23:05:27 php-fpm[85699]: /pkg_mgr_install.php: FreeRADIUS: Creating backup of the original file to /usr/pbi/freeradius-i386/local/etc/raddb/files.backup
      Nov 23 23:05:27 php-fpm[85699]: /pkg_mgr_install.php: FreeRADIUS: Creating backup of the original file to /usr/pbi/freeradius-i386/local/etc/raddb/policy.conf.backup
      Nov 23 23:05:02 check_reload_status: Syncing firewall
      Nov 23 23:04:57 php-fpm[85699]: /pkg_mgr_install.php: Beginning package installation for freeradius2 .

      @bfeitell:

      After banging on this for most of the day on a 4GB x86_64 nanobsd install I finally managed to get freeradius2 to install.

      I manually deleted the prior bad remnants by deleting /usr/pbi/freeradius-amd64

      Something is weird here because I had to manually dig down through the directory tree to delete everything.

      I then deleted /usr/local/pkg/freeradius.xml (there was no freeradius.inc file after failed attempts to intall via GUI).

      I then downloaded the latest platform specific freeradius package from https://files.pfsense.org/packages/10/All/ using fetch at the command line.

      I then installed the package at the command line forcing a verbose install using (in my platform specific case) pbi_add -v -f freeradius-2.2.6_3-amd64.pbi

      The install completed successfully, but the package did not appear as installed in the installed package GUI, or in the menus.

      I then reinstalled the package from "available packages", and the missing bits all fell into place.

      The odd bit for me is that I have freeradius installed on three other boxes I administer, one of which is completely identical, although all of them had the package installed several revisions ago with respect to both pfsense 2.2.

      I hope this helps someone else.

      Cheers,
      Bennett

      1 Reply Last reply Reply Quote 0
      • johnpozJ
        johnpoz LAYER 8 Global Moderator
        last edited by

        why would you follow some guide from 2012??  Installing the package is really click click..

        Are you running a nano image??

        An intelligent man is sometimes forced to be drunk to spend time with his fools
        If you get confused: Listen to the Music Play
        Please don't Chat/PM me for help, unless mod related
        SG-4860 24.11 | Lab VMs 2.7.2, 24.11

        1 Reply Last reply Reply Quote 0
        • S
          Snailkhan
          last edited by

          @johnpoz:

          why would you follow some guide from 2012??  Installing the package is really click click..

          Are you running a nano image??

          i though someone would say "letmegoogleitforyou"  so i did it myself and followed it after verifyign how packages are instaled on pfsense using command line . since it was official pbi file and using command line i though i would be able to see where it exactly gets stuck.. but using command line all was installed but couldnt start it..

          now i switched the slice (since running nano bsd) and i am getting error as in original post . so far i tried reinstalling the package .. removing and installing again ..  but no luck . duly rebooted after each step..

          Nov 25 01:22:24 php-fpm[20556]: /index.php: Successful login for user 'admin' from: 192.168.4.123
          Nov 25 01:22:24 php-fpm[20556]: /index.php: Successful login for user 'admin' from: 192.168.4.123
          Nov 25 01:22:15 php-fpm[20556]: /index.php: webConfigurator authentication error for 'admin' from 192.168.4.123
          Nov 25 01:22:15 php-fpm[20556]: /index.php: webConfigurator authentication error for 'admin' from 192.168.4.123
          Nov 25 01:17:06 php-fpm[97165]: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
          Nov 25 01:17:05 radiusd[16280]: Failed to load virtual server <default>Nov 25 01:17:05 radiusd[16280]: /usr/local/etc/raddb/sites-enabled/default[263]: Errors parsing authenticate section.
          Nov 25 01:17:05 radiusd[16280]: /usr/local/etc/raddb/sites-enabled/default[328]: Failed to find "eap" in the "modules" section.
          Nov 25 01:17:05 radiusd[16280]: /usr/local/etc/raddb/eap.conf[2]: Instantiation failed for module "eap"
          Nov 25 01:17:05 radiusd[16280]: rlm_eap: Failed to initialize type tls
          Nov 25 01:17:05 radiusd[16280]: rlm_eap_tls: Error reading private key file /usr/local/etc/raddb/certs/server.pem
          Nov 25 01:17:05 radiusd[16280]: rlm_eap: SSL error error:06065064:digital envelope routines:EVP_DecryptFinal_ex:bad decrypt
          Nov 25 01:17:05 php-fpm[97165]: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
          Nov 25 01:17:04 php-fpm[97165]: /rc.start_packages: Restarting/Starting all packages.
          Nov 25 01:17:03 check_reload_status: Reloading filter</default>

          besides when i run radius -X
          i get below errors

          }
          rlm_eap: SSL error error:06065064:digital envelope routines:EVP_DecryptFinal_ex:    bad decrypt
          rlm_eap_tls: Error reading private key file /usr/local/etc/raddb/certs/server.pe    m
          rlm_eap: Failed to initialize type tls
          /usr/local/etc/raddb/eap.conf[2]: Instantiation failed for module "eap"
          /usr/local/etc/raddb/sites-enabled/default[328]: Failed to find "eap" in the "mo    dules" section.
          /usr/local/etc/raddb/sites-enabled/default[263]: Errors parsing authenticate sec    tion.

          for above errors
          i found this thread
          https://forum.pfsense.org/index.php?topic=58901.0

          where it mentions

          From: http://freeradius.1045715.n5.nabble.com/trouble-seting-up-freeradius-td2768016.html
          Straight answer: Password you put in the configuration file of eap.conf have to be same the as the password used to create the private key.

          but i dont know what password is it being talked about ?
          i did created a ca and i do not remember supplying password to it.

          also what is the gibberish text in radiusd -X output

          1 Reply Last reply Reply Quote 0
          • S
            Snailkhan
            last edited by

            i did factory default of pfsense and restored using the configuration file exported earlier via builtin backup/restore ..
            but after restore same isssue .. as in just above update..

            Please help

            1 Reply Last reply Reply Quote 0
            • D
              doktornotor Banned
              last edited by

              Stop restoring broken configuration, perhaps. There's no such nonsense needed to get FreeRADIUS working really. If you followed some god knows what 3+years old howto, simply restart from scratch.

              1 Reply Last reply Reply Quote 0
              • S
                Snailkhan
                last edited by

                @doktornotor:

                Stop restoring broken configuration, perhaps. There's no such nonsense needed to get FreeRADIUS working really. If you followed some god knows what 3+years old howto, simply restart from scratch.

                i do not see that guide as invalid ..

                so is there anyway to reset the configs of freeradius to default ?

                1 Reply Last reply Reply Quote 0
                • D
                  doktornotor Banned
                  last edited by

                  Yeah. Edit the stuff out of config.xml backup and restore it.

                  1 Reply Last reply Reply Quote 0
                  • johnpozJ
                    johnpoz LAYER 8 Global Moderator
                    last edited by

                    What nano version do you have installed the 4GB one?

                    If freerad doesn't start its never going to work..  Really all you should have to do is click click to install the package..  I would have to fire up a copy of the nanobsd image to see if that has issues with installing the package?  If I get a chance to convert it to a vmdk I will boot it on my vm host and see if installs the package ok, etc.

                    An intelligent man is sometimes forced to be drunk to spend time with his fools
                    If you get confused: Listen to the Music Play
                    Please don't Chat/PM me for help, unless mod related
                    SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                    1 Reply Last reply Reply Quote 0
                    • johnpozJ
                      johnpoz LAYER 8 Global Moderator
                      last edited by

                      Ok, so I converted the img to vmdk, created a 64bit freebsd vm.. Added the disk, booted.. Ran through the config wizard.  Click Click on the freerad2 package.. Created an interface, bing bang zoom up and running.

                      Where in that guide does it have you create the nas/client for your host?  You have it listen on 127.0.0.1 (loopback) what IP are you talking from If you went through that guide blind did and not understanding what you were actually doing and just put in 192.168.10.253 like the guide not going to work.. And again if the service never start its never ever going to work..

                      freeradonnano.png
                      freeradonnano.png_thumb
                      authworking.png
                      authworking.png_thumb

                      An intelligent man is sometimes forced to be drunk to spend time with his fools
                      If you get confused: Listen to the Music Play
                      Please don't Chat/PM me for help, unless mod related
                      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                      1 Reply Last reply Reply Quote 0
                      • S
                        Snailkhan
                        last edited by

                        @johnpoz:

                        Ok, so I converted the img to vmdk, created a 64bit freebsd vm.. Added the disk, booted.. Ran through the config wizard.  Click Click on the freerad2 package.. Created an interface, bing bang zoom up and running.

                        Where in that guide does it have you create the nas/client for your host?  You have it listen on 127.0.0.1 (loopback) what IP are you talking from If you went through that guide blind did and not understanding what you were actually doing and just put in 192.168.10.253 like the guide not going to work.. And again if the service never start its never ever going to work..

                        Immense thanks for your replies .
                        yes i am on nanobsd 4gb image. 2gb ram. 32bit one.
                        ip addressing were obviously as per my setup when i tried to follow that article.

                        i configured nas for my AP but that was not working.

                        i also setup nas for loopback and tried to test as they said in that article but it wont work .

                        i only later found that the service was not runing.

                        it seems that configs are having some issue.

                        i will try to remove freeradius configs from backuped xml file and will try again  Factory defaulting it and restoring with modified backuped file.

                        Also is it necessary to factory default befor restoring the modified configs ? i mean is a restore overwrite function or a merge ?

                        1 Reply Last reply Reply Quote 0
                        • S
                          Snailkhan
                          last edited by

                          @johnpoz:

                          What nano version do you have installed the 4GB one?

                          If freerad doesn't start its never going to work..  Really all you should have to do is click click to install the package..  I would have to fire up a copy of the nanobsd image to see if that has issues with installing the package?  If I get a chance to convert it to a vmdk I will boot it on my vm host and see if installs the package ok, etc.

                          i have installed / uninstalled alot of times.

                          here is a log for reinstal which completes with sucess but cannot start service.

                          Removing freeradius2 components…
                          Tabs items... done.
                          Menu items... done.
                          Services... done.
                          Loading package instructions...
                          Deinstall commands... done.
                          Removing package instructions...done.
                          Auxiliary files... done.
                          Package XML... done.
                          Configuration... done.
                          Beginning package installation for freeradius2 .
                          Downloading package configuration file... done.
                          Saving updated package information... done.
                          Downloading freeradius2 and its dependencies...
                          Checking for package installation... Loading package configuration... done.
                          Configuring package components...
                          Loading package configuration... done.
                          Additional files... done.
                          Loading package instructions...
                          Custom commands...
                          Executing custom_php_install_command()...done.
                          Executing custom_php_resync_config_command()...done.
                          Menu items... done.
                          Integrated Tab items... done.
                          Services... done.
                          Writing configuration... done.

                          Package reinstalled.

                          logs for removal/installaiton wil be posted.

                          1 Reply Last reply Reply Quote 0
                          • S
                            Snailkhan
                            last edited by

                            I formated the thumb drive.
                            Using Rufus copied the 32bit nano bsd 4gb 2.2.5
                            Booted it.

                            Configured interfaces. Changed tmp and var sizes to 250mb.
                            System is 2gb ram and 1.6ghz1.6ghz atom n270

                            Tried to install free radius and after half hour still hanged / stuck at  extracting imageimage.
                            What's doing this? I had been running snort on it and it was working flawlessly once setup.. And was blocking attackes and I had tuned that…

                            Now no extra  package is installed. Also in all of my above tastings  though snort was installed but it was disabled on interfaces..

                            Update :

                            Accessed pfsense gui from another system.  Freeradius is not appearing in ui

                            But I tried the same image in VMware workstation and it worked perfectly.

                            Now it certainly is  local system issue but no idea what is it.

                            I have 4gb Kingston usb write speed 7-8 MBps.

                            In VMware I dd ed the image to a16 gb vmdk harddisk

                            I should have made it 4gb so that after installation of all required packages I could have dded it to my usb..

                            For that I need to make sure my vmdk size matches that of usb..

                            1 Reply Last reply Reply Quote 0
                            • johnpozJ
                              johnpoz LAYER 8 Global Moderator
                              last edited by

                              "In VMware I dd ed the image to a16 gb vmdk harddisk"

                              In vm if your using the nano, why would you make it a larger disk..  I just did a convert on the img to vmdk via v2v software.. Booted it..  Not sure why you think you need to change tmp and var sizes??

                              usb of 7-8MBps??  Uggghhh that is slow…  that is not even USB 2 speeds..

                              An intelligent man is sometimes forced to be drunk to spend time with his fools
                              If you get confused: Listen to the Music Play
                              Please don't Chat/PM me for help, unless mod related
                              SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                              1 Reply Last reply Reply Quote 0
                              • S
                                Snailkhan
                                last edited by

                                update:

                                yesterday i saw an update for freeradius and i reinstaleld it and now all is working..  strange  issue …

                                1 Reply Last reply Reply Quote 0
                                • First post
                                  Last post
                                Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.