Last updated
Last updated
This section describes technical implementation of Importing Setting from one Virtual Folder to another. For user's guide follow .
Because user's credentials are transfered via network, the settings are encrypted. Virtual Folder API generates asymetric 2048 bytes long RSA key and random symetric AES key for each transfer.
The following workflow will export settings from Virtual Folder Exported (VFE) instance (at https://portal.west-life.eu/virtualfolder) into Virtual Folder Import (VFI) instance at http://localhost:8081/virtualfolder. During import process it's possible to rename imported aliases:
To get public key from VFI instance, send POST request to VFI api/settings
.
The public key is returned as plain text in response body:
To obtain selected file providers from VFE instance, put the names of aliases (e.g. dropbox and experiment_pcloud) into SelectedAliases
query parameter and VFI public key into PublicKey
query parameter and send it as GET request to VFE api/settings
The response body from VFE contain encrypted settings using the RSA public key and AES encryption
To import the encrypted settings into VFI, attach public key, encrypted settings, old name aliases from VFE as parameter ConflictedAliases
and new names of aliases in the same order which will appear in VFI as parameter NewNameAliases
and send it as PUT request with e.g. the following json body (this example will import VFE b2drop as VFI b2drop_test)
The PUT request will return array of all registered aliases, where a new alias should appear at the end.
The above workflow is supported be backend web service wp6-virtualfolder/src/WP6Service2/WP6Service2/Services/Settings/SettingsExportImport.cs
and VFI frontend ui wp6-virtualfolder/www/src/virtualfoldersetting/importprovider.html
and VFE frontend ui wp6-virtualfolder/www/src/syncsetting/app.html
.