1. 24 Aug, 2015 4 commits
  2. 21 Aug, 2015 1 commit
  3. 20 Aug, 2015 4 commits
  4. 19 Aug, 2015 22 commits
    • Robin McCorkell's avatar
    • Robin McCorkell's avatar
      dc335ba5
    • Robin McCorkell's avatar
      d577aad4
    • Robin Appelman's avatar
    • Robin McCorkell's avatar
      Migrate SFTP external storage to new API · 16389270
      Robin McCorkell authored
      16389270
    • Robin McCorkell's avatar
      a99e5248
    • Robin McCorkell's avatar
      Migrate DAV external storage to new API · 68418bdd
      Robin McCorkell authored
      68418bdd
    • Robin McCorkell's avatar
      Migrate SMB external storage to new API · ab8c738b
      Robin McCorkell authored
      ab8c738b
    • Robin McCorkell's avatar
      Migrate FTP external storage to new API · 0f1809ec
      Robin McCorkell authored
      0f1809ec
    • Robin McCorkell's avatar
      0ffb51c6
    • Robin McCorkell's avatar
      Allow builtin auth mechanism to be overridden · 118cb7df
      Robin McCorkell authored
      The builtin mechanism is used exclusively for legacy external storages,
      which when upgraded to the new registration need to fallback to the
      defined legacy authentication mechanism instead.
      118cb7df
    • Robin McCorkell's avatar
      Implement password authentication mechanisms · 3bb793b6
      Robin McCorkell authored
      Introduces the basic password authentication mechanism, along with a
      mechanism based on ownCloud credentials stored in the user session.
      
      Change to lib/private is an extension of PermissionsMask, as
      isSharable() override was missing.
      
      Session credentials auth mechanism now disables sharing on applied
      storages, as credentials will not be available.
      3bb793b6
    • Robin McCorkell's avatar
      Restrict Local backend to admin-only · eb0e5ce1
      Robin McCorkell authored
      eb0e5ce1
    • Robin McCorkell's avatar
      Load custom JS for all backends/auth mechanisms · df8f5425
      Robin McCorkell authored
      Loading custom JS on a per-backend basis added needless complexity and
      made dealing with async required. Now all backends/auth mechanisms load
      custom JS in PHP
      df8f5425
    • Robin McCorkell's avatar
      Propagate auth mechanism/backend failures to filesystem layer · b6eb952a
      Robin McCorkell authored
      Failure to prepare the storage during backend or auth mechanism
      manipulation will throw an InsufficientDataForMeaningfulAnswerException,
      which is propagated to StorageNotAvailableException in the filesystem
      layer via the FailedStorage helper class.
      
      When a storage is unavailable not due to failure, but due to
      insufficient data being available, a special 'indeterminate' status is
      returned to the configuration UI.
      b6eb952a
    • Robin McCorkell's avatar
      Make Application a singleton · c592e24c
      Robin McCorkell authored
      The same Application must be used in the settings templates and in
      routes, so that any registered backends are correctly seen
      c592e24c
    • Robin McCorkell's avatar
      Compatibility shims for OC_Mount_Config · 97dbc79c
      Robin McCorkell authored
      The following functions have been removed:
       - addMountPoint()
       - removeMountPoint()
       - movePersonalMountPoint()
      
      registerBackend() has been rewritten as a shim around BackendService,
      allowing legacy code to interact with the new API seamlessly
      
      addMountPoint() was already disconnected from all production code, so
      this commit completes the job and removes the function itself, along
      with disconnecting and removing related functions. Unit tests have
      likewise been removed.
      
      getAbsoluteMountPoints(), getSystemMountPoints() and
      getPersonalMountPoints() have been rewritten to use the StoragesServices
      97dbc79c
    • Robin McCorkell's avatar
      Unit tests for new backend API · c5726310
      Robin McCorkell authored
      c5726310
    • Robin McCorkell's avatar
      Split backend identifiers from the class name · 1eeca031
      Robin McCorkell authored
      Prior to this, the storage class name was stored in mount.json under the
      "class" parameter, and the auth mechanism class name under the
      "authMechanism" parameter. This decouples the class name from the
      identifier used to retrieve the backend or auth mechanism.
      
      Now, backends/auth mechanisms have a unique identifier, which is saved in
      the "backend" or "authMechanism" parameter in mount.json respectively.
      An identifier is considered unique for the object it references, but the
      underlying class may change (e.g. files_external gets pulled into core
      and namespaces are modified).
      1eeca031
    • Robin McCorkell's avatar
      Authentication mechanisms for external storage backends · 272a46eb
      Robin McCorkell authored
      A backend can now specify generic authentication schemes that it
      supports, instead of specifying the parameters for its authentication
      method directly. This allows multiple authentication mechanisms to be
      implemented for a single scheme, providing altered functionality.
      
      This commit introduces the backend framework for this feature, and so at
      this point the UI will be broken as the frontend does not specify the
      required information.
      
      Terminology:
       - authentication scheme
          Parameter interface for the authentication method. A backend
          supporting the 'password' scheme accepts two parameters, 'user' and
          'password'.
       - authentication mechanism
          Specific mechanism implementing a scheme. Basic mechanisms may
          forward configuration options directly to the backend, more advanced
          ones may lookup parameters or retrieve them from the session
      
      New dropdown selector for external storage configurations to select the
      authentication mechanism to be used.
      
      Authentication mechanisms can have visibilities, just like backends.
      The API was extended too to make it easier to add/remove visibilities.
      In addition, the concept of 'allowed visibility' has been introduced, so
      a backend/auth mechanism can force a maximum visibility level (e.g.
      Local storage type) that cannot be overridden by configuration in the
      web UI.
      
      An authentication mechanism is a fully instantiated implementation. This
      allows an implementation to have dependencies injected into it, e.g. an
      \OCP\IDB for database operations.
      
      When a StorageConfig is being prepared for mounting, the authentication
      mechanism implementation has manipulateStorage() called,
      which inserts the relevant authentication method options into the
      storage ready for mounting.
      272a46eb
    • Robin McCorkell's avatar
      Introduce UserGlobalStoragesService · a6a69ef1
      Robin McCorkell authored
      UserGlobalStoragesService reads the global storage configuration,
      cherry-picking storages applicable to a user. Writing storages through
      this service is forbidden, on punishment of throwing an exception.
      Storage IDs may also be config hashes when retrieved from this service,
      as it is unable to update the storages with real IDs.
      
      As UserGlobalStoragesService and UserStoragesService share a bit of code
      relating to users, that has been split into UserTrait. UserTrait also
      allows for the user set to be overridden, rather than using the user
      from IUserSession.
      
      Config\ConfigAdapter has been reworked to use UserStoragesService and
      UserGlobalStoragesService instead of
      OC_Mount_Config::getAbsoluteMountPoints(), further reducing dependance
      on that horrible static class.
      a6a69ef1
    • Robin McCorkell's avatar
      Introduce BackendService for managing external storage backends · 37beb58c
      Robin McCorkell authored
      Backends are registered to the BackendService through new data
      structures:
      
      Backends are concrete classes, deriving from
      \OCA\Files_External\Lib\Backend\Backend. During construction, the
      various configuration parameters of the Backend can be set, in a design
      similar to Symfony Console.
      
      DefinitionParameter stores a parameter configuration for an external
      storage: name of parameter, human-readable name, type of parameter
      (text, password, hidden, checkbox), flags (optional or not).
      
      Storages in the StoragesController now get their parameters validated
      server-side (fixes a TODO).
      37beb58c
  5. 17 Aug, 2015 1 commit
  6. 14 Aug, 2015 1 commit
  7. 13 Aug, 2015 1 commit
  8. 10 Aug, 2015 1 commit
  9. 05 Aug, 2015 1 commit
  10. 03 Aug, 2015 1 commit
  11. 28 Jul, 2015 2 commits
  12. 21 Jul, 2015 1 commit