Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Timothee

Pages: [1] 2 3 ... 7
1
Support for VAM 2.4 - 2.6 / Re: Flight ID char logic
« on: November 16, 2020, 03:40:25 PM »
As drgullen described correctly, the string is generated by SIM ACARS to ensure the flight number is unique, even if two pilots start the same flight at the same time.
Therefore the string before the flight number is something like year (yyyy), month (M), day (d), hour (H), minute (m), seconds (s), milliseconds (fff). Every number is without leading zeros.




2
So I noticed that, depending on which SQL modes have been set in the database, a few queries do not work anymore.

Regarding people not able to send reports there might occur multiple problems.

First of all, the following variable may be set: NO_ZERO_DATE.
In a few tables (gvausers, vampireps, etc.) the default value for timestamps has been set to 0000-00-00 00:00:00. With this variable set, this value is not valid. Unfortunately it is not possible to alter said tables. Therefore you have to export them, drop the table, modify the exported create table statement and import the table again.
For the table vampireps the affected field is "updated_at". Set the default value to NULL (and allow the field to be NULL).

Furthermore STRICT_ALL_TABLES or STRICT_TRANS_TABLES may be set. With one of those set, INSERT and UPDATE statements will fail if fields without a default value are missing.
In the table vampireps there are four fields (virtual_airline, va_url, paid and vam_route) without a default value. Set a default value for all of them:
virtual_airline: empty string
va_url: empty string
paid: 0
vam_route: 0

You can check the sql_mode variables in PhpMyAdmin.

SIM ACARS sends report via receivevampirep.php. The expected output is always "OK" or "DUPLICATED". Any other output (for example SQL errors) will show the misleading error "During data trasmission some data inconsistency was found...".

3
Support for VAM 2.4 - 2.6 / Re: Problems with the statistical pages
« on: June 19, 2020, 02:11:38 PM »
Ah right there was another one.
You need to edit the file pilot_profile_stats_sql.php.

On line 25 there should be the following SQL statement:
Code: [Select]
$sql="select AVG (distance) as distance_avg , AVG(flight_duration) as duration_avg , AVG(landing_vs) as landingvs_avg from vampireps where gvauser_id=$pilotid
union
select AVG (DistanceFlight) as distance_avg , AVG(FlightTime) as duration_avg , CASE  WHEN DistanceFlight IS NULL then 0 else AVG(LandingVS) END as landingvs_avg from pirepfsfk where gvauser_id=$pilotid";

Change it to the following:
Code: [Select]
$sql="select AVG (distance) as distance_avg , AVG(flight_duration) as duration_avg , AVG(landing_vs) as landingvs_avg, ROUND(AVG(rating)) as rating_avg from vampireps where gvauser_id=$pilotid
union
select AVG (DistanceFlight) as distance_avg , AVG(FlightTime) as duration_avg , CASE  WHEN DistanceFlight IS NULL then 0 else AVG(LandingVS) END as landingvs_avg, ROUND(AVG(rating)) as rating_avg from pirepfsfk where gvauser_id=$pilotid group by DistanceFlight";

4
Support for SIM ACARS / Re: Live flights not showing
« on: June 19, 2020, 12:55:33 PM »
SIM ACARS calls vamliveacars.php about every minute during an active flight. From there the tables vam_live_acars and vam_live_flights will be populated.

Is this file present in your installation and if yes have you modified it?

5
Support for VAM 2.4 - 2.6 / Re: Problems with the statistical pages
« on: June 19, 2020, 12:50:15 PM »
Hi

I had the same error after MySQL got upgraded to a new version. The cause for this error is an invalid view "v_flights_pilots".
You have to delete it and recreate it using the following SQL command:

Code: [Select]
CREATE ALGORITHM=UNDEFINED SQL SECURITY DEFINER VIEW `v_flights_pilots`  AS  select count(`reports`.`report_id`) AS `c`,date_format(`reports`.`date`,'%Y-%m-%d') AS `flightdate`,`reports`.`pilot_id` AS `pilot`,'fsacars' AS `type` from `reports` group by `reports`.`pilot_id`,`reports`.`date` union select count(`pireps`.`pirep_id`) AS `c`,date_format(`pireps`.`date`,'%Y-%m-%d') AS `flightdate`,`pireps`.`gvauser_id` AS `pilot`,'manual' AS `type` from `pireps` group by `pireps`.`gvauser_id`,`pireps`.`date` union select count(`pirepfsfk`.`pirepfsfk_id`) AS `c`,date_format(`pirepfsfk`.`CreatedOn`,'%Y-%m-%d') AS `flightdate`,`pirepfsfk`.`gvauser_id` AS `pilot`,'fskeeper' AS `type` from `pirepfsfk` group by `pirepfsfk`.`pirepfsfk_id`,`pirepfsfk`.`CreatedOn` union select count(`vampireps`.`flightid`) AS `c`,date_format(`vampireps`.`flight_date`,'%Y-%m-%d') AS `flightdate`,`vampireps`.`gvauser_id` AS `pilot`,'vamkeeper' AS `type` from `vampireps` group by `vampireps`.`gvauser_id`,date_format(`vampireps`.`flight_date`,'%Y-%m-%d');

With sql_mode=only_full_group_by the GROUP BY statement must contain all fields not using an aggregate function.

6
Well but HTTP error 406 looks already more promising. This means the SSL/TLS connection was established.

However, SIM ACARS does not 100 percent comply with the HTTP standard. This may lead to other problems with mod_security for example. HTTP 406 could mean, that some HTTP headers are missing. Have you tried looking in that direction?

7
Hi

If I remember correctly from the last time I noticed that SIM ACARS is always using TLS 1.0 when a HTTPS URL is used. Don't know why, maybe it is hardcoded.
However, you can override the settings from SIM ACARS, not sure if this will work in your case: http://virtualairlinesmanager.net/foro//index.php?topic=1886.msg7311#msg7311

And just as a personal hint. You should use at least TLS 1.2. SSL is considered insecure and should not be used anymore.

Regards

8
Support for SIM ACARS / Re: Airport with 3 letters code - ERROR
« on: May 15, 2020, 08:15:39 PM »
5KE is not the IATA identifier but the FAA code. The IATA code is WFB.
But it looks like this airport has no ICAO code assigned.

Funny enough, this airport does exist in the SIM ACARS database but it looks like it is hard coded into the UI to only accept 4 letter codes.
There is nothing we can do about that.

9
Support for VAM 2.4 - 2.6 / Re: Ranks Not updating
« on: January 29, 2020, 12:23:12 PM »
Hi, do you know what was problem ? how can I repair autopdate rank ?

Hi Arionix

a long time ago I posted a bug about ranks not updating. Maybe this affects you as, well actually every VAM installation is affected if more than 5 pilots are flying.
Have a look here on how to fix it: http://virtualairlinesmanager.net/foro//index.php?topic=1087

Regards


10
Thats nothing I can answer. I don't know what you or your hoster has in place.

11
So obviously there is some enhanced security running on your webserver (probably a web application firewall like Apache mod_security or something similiar).
Thats nothing bad but may cause problems because SIMACARS doesnt care that much about standards. For example, SIMACARS uses the Content-Type text/json. This Content-Type does not exists and should be application/json.

As soon as you press the login button in SIMACARS tries to call (POST) the following three files:
http://uflygroup.ga/virtualairline/vam/vam_acars_remove_book_aircraft.php
http://uflygroup.ga/virtualairline/vam/vam_acars_get_aircraft.php
http://uflygroup.ga/virtualairline/vam/vam_acars_pilot_connection.php

Doing this with SIMACARS the webserver returns an HTTP 403 Forbidden error, instead of HTTP 200 OK. Additionally to that, it looks like my IP is blocked from any further try.

In short, it is a security setting on your webserver or from your hoster.  What you can change or have to change in order to get SIMACARS running is to disable some security features or to make an exception.

12
Hi

There are so many things which could go wrong in this scenario (wrong TLS version if using HTTPS, Apache mod_security misconfiguration, etc.). However, mostly Wireshark is pretty helpful to find the cause of the errors. If you don't know how to use it, it would be helpful to know the URL of your VA. I will check if I see any obvious errors.

Regards

13
Hi

Did something similiar, although I'm using a different destination.
I'm assuming you want to change the link on the pilot roster.

Edit the file pilots_public.php and look for the following lines:

Code: [Select]
  if ($vatsim == 1) {
    echo '<td><a href="https://stats.vatsim.net/search_id.php?id=' . $row["vatsimid"] . '">' . $row["vatsimid"] . '</a></td>';
  }

Change the target to whatever you want.

14
Hi Peter

I havent decided about that yet. For the moment its just for internal use.
There are two reasons for that. Firstly although my program is compatible with VAM I havent implemented charter flights simply because we dont support it in our airline. Secondly we have only a limited set of aircrafts available and some addons like the Majestic Dash or the PMDG 777 need some special handling for detecting lights and there might be more out there.

That said, if its ever getting released to the public it will be either Freeware or Open Source.

I am using C# but once released I will be happy to come back to you.

Regards
Timothee

15
Hi Peter

I do agree with you. We realized this fact a while ago already. A project maintained by only one person is sooner or later going to die.

We made a lot of modifications to VAM itself so it wouldnt be compatible anymore anyway. Also, two years ago I started writing our own ACARS client which is compatible with VAM and resolves issues which SIM ACARS had. The client is still in testing internally but the results are looking fine.

With this we are now fully independent since I don't expect anything new from here.

Regards
Timothee

Pages: [1] 2 3 ... 7