FA 2.4.x now has a few hidden fields in the login form apart from the ones listed in @elax previous post:
<input id="ui_mode" name="ui_mode" value="1" type="hidden">
..
..
<input name="_focus" value="user_name_entry_field" type="hidden">
<input name="_modified" value="0" type="hidden">
<input name="_confirmed" value="" type="hidden">
<input name="_token" value="iwyLHJUcoMkfRv8-ZpBQVwxx" type="hidden">
The _token field will come up on calling the login form and must be parsed out and submitted with the field values in cURL.
TOKENCODE=`curl -c my_session http://localhost/frontac24/ | sed -ne '/name="_token"/s/.*value="\([^"]*\)".*/\1/p'`
The following would log you in where your admin user's password is "secret":
curl -c my_session \
-F 'user_name_entry_field=admin' \
-F 'password=secret' \
-F 'company_login_name=1' \
-F 'ui_mode=1' \
-F 'modified=0' \
-F 'confirmed=1' \
-F "_token=${TOKENCODE}" \
-F '_focus=user_name_entry_field' \
http://localhost/frontac24/ > logged_in_page.txt
The file "logged_in_page.txt" will contain the html code for the FA's logged in page.
To study the parameters required for the Sales Summary Report:
curl -b my_session \
-F 'Class=0' \
-F 'REP_ID=114' \
http://localhost/frontac24/reporting/reports_main.php > report_form.txt
To get the Sales Summary Report:
curl -b my_session \
-F 'REP_ID=114' \
-F 'PARAM_0=01/01/2015' \
-F 'PARAM_1=10/31/2017' \
-F 'PARAM_2=0' \
-F 'PARAM_3=AutoSalesSummaryReport' \
-F 'PARAM_4=0' \
-F 'PARAM_5=0' \
-F 'Class=0' \
http://localhost/frontac24/reporting/rep114.php > Sales_Summary_Report.pdf
Now to logout:
curl -b my_session http://localhost/frontac24/access/logout.php? > logged_out_page.txt
The "logged_out_page.txt" will contain the html code for the logged out page.