ISignedCloudFederationProvider.php 811 B

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2018 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. namespace NCU\Federation;
  8. use OCP\Federation\ICloudFederationProvider;
  9. /**
  10. * Interface ICloudFederationProvider
  11. *
  12. * Enable apps to create their own cloud federation provider
  13. *
  14. * @experimental 31.0.0
  15. */
  16. interface ISignedCloudFederationProvider extends ICloudFederationProvider {
  17. /**
  18. * returns federationId in direct relation (as recipient or as author) of a sharedSecret
  19. * the federationId must be the one at the remote end
  20. *
  21. * @param string $sharedSecret
  22. * @param array $payload
  23. *
  24. * @experimental 31.0.0
  25. * @return string
  26. */
  27. public function getFederationIdFromSharedSecret(string $sharedSecret, array $payload): string;
  28. }