UploadDiagnostics how does it work and how to use that?

I know that question is not strictly connected to GenieACS but maybe someone can help me :slight_smile:

My working example for DownloadDiagnostics (it’s clear for me):

curl -i 'http://localhost:7557/devices/F48CEB-Router-QXNN1J1004416/tasks?connection_request' -X POST --data '{"name":"setParameterValues", "parameterValues":[["InternetGatewayDevice.DownloadDiagnostics.DiagnosticsState", "Requested", "xsd:string"],["InternetGatewayDevice.DownloadDiagnostics.DownloadURL", "http://www.ovh.net/files/100Mb.dat", "xsd:string"]]}'

However UploadDiagnostics it’s not clear. I dont’t know how exacly upload diagnostics work.

I will be grateful for example how to use UploadDiagnostics with curl.

Please review the TR for this. If you still have issues figuring this out after giving it an honest go, I will take the time to write some stuff up.

-dan

I know the theory, but one example should solve my problem. Any example, not necessarily using curls. Generally, I don’t know how to “pass” the file that will be used to test the upload speed.

I will be grateful for the practical example.

Thats specified by InternetGatewayDevice.UploadDiagnostics.UploadURL.

The URL can be either FTP or HTTP, depending on value(s) in InternetGatewayDevice.Capabilities.PerformanceDiagnostic.UploadTransports. If you do FTP, the receiving FTP server has to either allow anonymous writes, or your CPE has to support FTP auth. FTP authentication is not part of the spec so it would require vendor support. If you choose FTP, I recommend you limit uploads to within your IP space and run a cron job every minute which purges all files older than 10 minutes. This will limit the attack surface and hopefully prevent your FTP server from being used as a drop for illicit files.

For example is this valid UploadURL: ftp://anonymous@ftp.domain.com/myTestFileForUploadDiagnostics.bin ?

That’s all or should do some extra stuff?

ftp://ftp.domain.com/myTestFileForUploadDiagnostics.bin