Hi Fabrice, list,

On 13-7-2017 2:23, Durand fabrice via PacketFence-users wrote:
when it happen, can you check in the database just after the duration has been 
extended ?
select * from node where mac="9c:2a:70:31:9b:9f';

ok, here it is:

after the link in the registration email has been clicked, the screen message says: "email activation code has been verified. Access granted until: 2017:08-06 16:20:31"
That is CORRECT, with the expected duration

However, the GUI is then still saying: "Unregistration 2017-07-17 16:40"
That is WRONG!

At that time, the database says:
MariaDB [pf]> select * from node where mac =  'b8:08:cf:58:4d:f0';
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
| mac               | pid               | category_id | detect_date         | 
regdate             | unregdate           | lastskip            | time_balance 
| bandwidth_balance | status | user_agent | computername           | notes | 
last_arp            | last_dhcp           | dhcp_fingerprint                    
                   | dhcp6_fingerprint | dhcp_vendor | dhcp6_enterprise | 
device_type        | device_class | device_version | device_score | bypass_vlan 
| voip | autoreg | sessionid | machine_account | bypass_role_id | last_seen     
      |
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
| b8:08:cf:58:4d:f0 | [email protected] |           2 | 2017-07-17 16:20:14 | 
2017-07-17 16:20:31 | 2017-07-17 16:40:31 | 0000-00-00 00:00:00 |         NULL 
|              NULL | reg    |            | user-Latitude-E7470 |       | 
0000-00-00 00:00:00 | 2017-07-17 16:21:32 | 
1,28,2,3,15,6,119,12,44,47,26,121,42,121,249,33,252,42 |                   |    
         |                  | Debian-based Linux | Linux        | NULL          
 | 80           |             | no   | no      |           | NULL            |  
         NULL | 2017-07-17 16:22:15 |
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
1 row in set (0.00 sec)

It seems to me that the duration extension after clicking the confirmation link is never actually recorded into the database? At this time, in the GUI under Reports, the httpd.portal email registration is still listed as *incomplete*
Which I feel is WRONG. (is *complete*, from the users perspective)

Then, after my access expired, I try the same thing again, only, my mac address already exists in the database, but in unreg state. I am presented with the registration portal, and register again using the same details. Receive 20 minutes temp network access, plus a new verification link.

When I click that new verification link, the unregistration date is successfully recorded into the pf database:

MariaDB [pf]> select * from node where mac =  'b8:08:cf:58:4d:f0';
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
| mac               | pid               | category_id | detect_date         | 
regdate             | unregdate           | lastskip            | time_balance 
| bandwidth_balance | status | user_agent | computername           | notes | 
last_arp            | last_dhcp           | dhcp_fingerprint                    
                   | dhcp6_fingerprint | dhcp_vendor | dhcp6_enterprise | 
device_type        | device_class | device_version | device_score | bypass_vlan 
| voip | autoreg | sessionid | machine_account | bypass_role_id | last_seen     
      |
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
| b8:08:cf:58:4d:f0 | [email protected] |           2 | 2017-07-17 16:20:14 | 
2017-07-17 16:42:45 | 2017-08-16 16:42:45 | 0000-00-00 00:00:00 |         NULL 
|              NULL | reg    |            | username-Latitude-E7470 |       | 
0000-00-00 00:00:00 | 2017-07-17 16:42:05 | 
1,28,2,3,15,6,119,12,44,47,26,121,42,121,249,33,252,42 |                   |    
         |                  | Debian-based Linux | Linux        | NULL          
 | 80           |             | no   | no      |           | NULL            |  
         NULL | 2017-07-17 16:47:20 |
+-------------------+-------------------+-------------+---------------------+---------------------+---------------------+---------------------+--------------+-------------------+--------+------------+------------------------+-------+---------------------+---------------------+--------------------------------------------------------+-------------------+-------------+------------------+--------------------+--------------+----------------+--------------+-------------+------+---------+-----------+-----------------+----------------+---------------------+
1 row in set (0.00 sec)

MariaDB [pf]>

However, in the GUI, under Reports:
- the httpd.portal 1st email reg try is still listed as *invalidated* (correct, i guess)
- the httpd.portal 2nd email reg try is still listed as *incomplete*
(wrong, as this one succeeded)

This is an upgraded install from 5.6, and I think I ran all database upgrades.

Anyway ideas why this is happening..?

MJ

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
PacketFence-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/packetfence-users

Reply via email to