Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Loading remote bbs+ context failed because of redirect #2738

Closed
truonghaha opened this issue Jan 29, 2024 · 0 comments · Fixed by #2749
Closed

Loading remote bbs+ context failed because of redirect #2738

truonghaha opened this issue Jan 29, 2024 · 0 comments · Fixed by #2749
Assignees

Comments

@truonghaha
Copy link

truonghaha commented Jan 29, 2024

Hi team, I got this error while issuing the VC using the BBS signature, seems like the context https://w3id.org/security/bbs/v1 is outdated.

Traceback (most recent call last):
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
  File "/usr/src/app/aries_cloudagent/admin/server.py", line 181, in ready_middleware
    return await handler(request)
  File "/usr/src/app/aries_cloudagent/admin/server.py", line 218, in debug_middleware
    return await handler(request)
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/aiohttp_apispec/middlewares.py", line 45, in validation_middleware
    return await handler(request)
  File "/usr/src/app/aries_cloudagent/admin/server.py", line 337, in check_token
    return await handler(request)
  File "/usr/src/app/aries_cloudagent/admin/server.py", line 386, in check_multitenant_authorization
    return await handler(request)
  File "/usr/src/app/aries_cloudagent/admin/server.py", line 451, in setup_context
    return await task
  File "/usr/local/lib/python3.9/asyncio/futures.py", line 284, in __await__
    yield self  # This tells Task to wait for completion.
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 328, in __wakeup
    future.result()
  File "/usr/local/lib/python3.9/asyncio/futures.py", line 201, in result
    raise self._exception
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 256, in __step
    result = coro.send(None)
  File "/usr/src/app/aries_cloudagent/protocols/issue_credential/v2_0/routes.py", line 1125, in credential_exchange_send_bound_offer
    (cred_ex_record, cred_offer_message) = await cred_manager.create_offer(
  File "/usr/src/app/aries_cloudagent/protocols/issue_credential/v2_0/manager.py", line 230, in create_offer
    await cred_format.handler(self.profile).create_offer(
  File "/usr/src/app/aries_cloudagent/protocols/issue_credential/v2_0/formats/ld_proof/handler.py", line 179, in create_offer
    missing_properties = get_properties_without_context(
  File "/usr/src/app/aries_cloudagent/vc/ld_proofs/check.py", line 137, in get_properties_without_context
    compact = jsonld.compact(
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/pyld/jsonld.py", line 142, in compact
    return JsonLdProcessor().compact(input_, ctx, options)
  File "/root/.cache/pypoetry/virtualenvs/aries-cloudagent-VA82Wl8V-py3.9/lib/python3.9/site-packages/pyld/jsonld.py", line 719, in compact
    raise JsonLdError(
pyld.jsonld.JsonLdError: ('Could not expand input before compaction.',)
Type: jsonld.CompactError
Cause: ('Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context.',)
Type: jsonld.InvalidUrl
Code: loading remote context failed
Details: {'url': 'https://w3id.org/security/bbs/v1', 'cause': JsonLdError('Could not retrieve a JSON-LD document from the URL.')}

Accessed this context URL from the browser will redirect me to another endpoint https://w3c.github.io/vc-di-bbs/contexts/v1, should we use this new context URL for BBS signature instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants