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

fix: allow reconnections to a multi-use invitation. #1395

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions packages/core/src/modules/oob/OutOfBandApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -391,21 +391,6 @@ export class OutOfBandApi {
)
}

// Make sure we haven't received this invitation before
// It's fine if we created it (means that we are connnecting to ourselves) or if it's an implicit
// invitation (it allows to connect multiple times to the same public did)
if (!config.isImplicit) {
const existingOobRecordsFromThisId = await this.outOfBandService.findAllByQuery(this.agentContext, {
invitationId: outOfBandInvitation.id,
role: OutOfBandRole.Receiver,
})
if (existingOobRecordsFromThisId.length > 0) {
throw new AriesFrameworkError(
`An out of band record with invitation ${outOfBandInvitation.id} has already been received. Invitations should have a unique id.`
)
}
}

const recipientKeyFingerprints: string[] = []
for (const service of outOfBandInvitation.getServices()) {
// Resolve dids to DIDDocs to retrieve services
Expand Down