simonsobs / simonsobs/ocs

Restrict feed name allowed characters

Open
#134 0 comments 0 reactions 0 assignees View on GitHub

A pull request for this has already been merged.

  • #137 by @jlashner — merged
enhancement
Dominant language
Python
Stars
19
Forks
7
PR merge metrics
No merged PRs in 30d

Description

Feed names end up as part of a crossbar URI for pub/sub. crossbar has restrictions on what characters are allowed in these URIs as defined here: https://crossbar.io/docs/URI-Format/

We should restrict feed names to these rules so that users can't accidentally generate improper URI names.

These are the rules from crossbar:

  • Allowed characters are lower case letters, numbers, ‘.’ and ‘_’. (Lower case letters are used to ensure compatibility with languages which have case-insensitive identifiers.)
  • There can be no non-empty parts between the separating full-stops, e.g. com.expressweasel.user..start is not a valid URI. (It could be used as part of patter-based subscriptions/registrations though.)
  • wamp as an inital URI part is not allowed, since this is reserved for URIs predefined with the WAMP protocol itself.
  • crossbar as an initial URI part is not allowed, since this is used by Crossbar.io itself for internal messaging.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is identified in the issue. Start by tracing where feed names are accepted and converted into Crossbar pub/sub URIs, then compare that path with the linked Crossbar URI rules; done means invalid names are rejected and valid names remain accepted.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
distributed-systems
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.