Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
2974bd3
Update match-maker-client.js
sevenbitbyte Mar 25, 2026
34d7484
add runner to EndpointContext
nullagent May 18, 2026
3b407d6
key management and ephemeral sessions
nullagent May 18, 2026
6df2d70
cleanup ephemeral sessions every 15 minutes
nullagent May 18, 2026
8ddc422
admin only access to API
nullagent May 25, 2026
015a46b
debounce start
nullagent May 25, 2026
1bd2b5c
build with tar of static files and add file hashes & signing to servi…
nullagent May 29, 2026
aac16e1
packages uploading during build but not finished yet
nullagent May 30, 2026
c022c12
hash tar file during build
nullagent May 30, 2026
09ab900
verifying service & tars, saving files to disc
nullagent May 31, 2026
1c794ad
services written to db
nullagent May 31, 2026
2b68a1d
regular expression for safeworkspace path and move file save to after…
nullagent May 31, 2026
1890907
initial project schema
nullagent Jun 2, 2026
7a08ea0
move reasable package parts
nullagent Jun 9, 2026
237adf2
venued commands
nullagent Jun 10, 2026
e94db4e
moar commands
nullagent Jun 10, 2026
b6e4ac7
venue package build
nullagent Jun 10, 2026
690a542
i2p tweaks
sevenbitbyte Jun 12, 2026
df68ba3
initial create project
nullagent Jun 13, 2026
45cfb17
install i2p script ubuntu
nullagent Jun 13, 2026
de356a4
Merge branch 'billing-checkout-client' of github.com:datapartyjs/data…
nullagent Jun 13, 2026
2fa54e8
clean up regression in schema generation
nullagent Jun 13, 2026
b68cfb7
move sig
nullagent Jun 14, 2026
2159b3b
origin router fork
nullagent Jun 14, 2026
1ee6319
ephemeral-client
nullagent Jun 14, 2026
9ec28a0
autoreconnect
nullagent Jun 14, 2026
4f2f2c8
improve reconnect timer math
nullagent Jun 14, 2026
9fc0dc2
clean top level signals
nullagent Jun 14, 2026
68d4800
sane defaults
nullagent Jun 14, 2026
affd9c8
randomize reconnect timing
nullagent Jun 14, 2026
90b3d9d
add timing info
nullagent Jun 14, 2026
68f5446
project build
nullagent Jun 14, 2026
f3d0e3b
suport deploy
nullagent Jun 14, 2026
a393621
clients
nullagent Jun 16, 2026
270c5e8
cleanup duplicate code
nullagent Jun 19, 2026
3ec1a77
missed cleanup task move and add start of peer client
nullagent Jun 19, 2026
8151261
improve role logic and access in PeerInvite
nullagent Jun 20, 2026
ca50083
matchmaker client identity
nullagent Jun 20, 2026
32f6005
plumbing model
nullagent Jun 20, 2026
c116a77
model, socket, internal calls plumbing
nullagent Jun 20, 2026
fc84be8
plumb access controls better
nullagent Jun 20, 2026
eea8375
project staticTar handling
nullagent Jun 20, 2026
53d0437
tar handling in package
nullagent Jun 21, 2026
fde4fb3
project flow fixes
nullagent Jun 21, 2026
44b8210
cleanup package and project creation
nullagent Jun 21, 2026
3cd8232
dynamic loading
nullagent Jun 21, 2026
c9b81e2
static file hosting working
nullagent Jun 21, 2026
fdad1c5
venue remote repl
sevenbitbyte Jun 28, 2026
f27761e
peer query handler
sevenbitbyte Jun 28, 2026
54935f9
version bump
sevenbitbyte Jun 28, 2026
50f3021
code of conduct
sevenbitbyte Jul 1, 2026
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
94 changes: 94 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@

# Contributor Covenant 3.0 Code of Conduct

## Our Pledge

We pledge to make our community welcoming, safe, and equitable for all.

We are committed to fostering an environment that respects and promotes the dignity, rights, and contributions of all individuals, regardless of characteristics including race, ethnicity, caste, color, age, physical characteristics, neurodiversity, disability, sex or gender, gender identity or expression, sexual orientation, language, philosophy or religion, national or social origin, socio-economic position, level of education, or other status. The same privileges of participation are extended to everyone who participates in good faith and in accordance with this Covenant.

## Encouraged Behaviors

While acknowledging differences in social norms, we all strive to meet our community's expectations for positive behavior. We also understand that our words and actions may be interpreted differently than we intend based on culture, background, or native language.

With these considerations in mind, we agree to behave mindfully toward each other and act in ways that center our shared values, including:

1. Respecting the **purpose of our community**, our activities, and our ways of gathering.
2. Engaging **kindly and honestly** with others.
3. Respecting **different viewpoints** and experiences.
4. **Taking responsibility** for our actions and contributions.
5. Gracefully giving and accepting **constructive feedback**.
6. Committing to **repairing harm** when it occurs.
7. Behaving in other ways that promote and sustain the **well-being of our community**.


## Restricted Behaviors

We agree to restrict the following behaviors in our community. Instances, threats, and promotion of these behaviors are violations of this Code of Conduct.

1. **Harassment.** Violating explicitly expressed boundaries or engaging in unnecessary personal attention after any clear request to stop.
2. **Character attacks.** Making insulting, demeaning, or pejorative comments directed at a community member or group of people.
3. **Stereotyping or discrimination.** Characterizing anyone’s personality or behavior on the basis of immutable identities or traits.
4. **Sexualization.** Behaving in a way that would generally be considered inappropriately intimate in the context or purpose of the community.
5. **Violating confidentiality**. Sharing or acting on a person's or Dataparty LLC's personal or private information without their express permission.
6. **Endangerment.** Causing, encouraging, or threatening violence or other harm toward any person or group.
7. Behaving in other ways that **threaten the well-being** of our community.
8. **Gaslighting.** Denying, misdirecting, lying or other means of refusing accountability despite clear evidence.
9. **Distraction** Sustained disruption of events or communications.
10. **Triangulation** Unnecesarily involving 3rd parties in moderation decisions.

### Other Restrictions

1. **Misleading identity.** Impersonating someone else for any reason, or pretending to be someone else to evade enforcement actions.
2. **Failing to credit sources.** Not properly crediting the sources of content you contribute.
3. **Promotional materials**. Sharing marketing or other commercial content in a way that is outside the norms of the community.
4. **Irresponsible communication.** Failing to responsibly present content which includes, links or describes any other restricted behaviors.


## Reporting an Issue

Tensions can occur between community members even when they are trying their best to collaborate. Not every conflict represents a code of conduct violation, and this Code of Conduct reinforces encouraged behaviors and norms that can help avoid conflicts and minimize harm.

When an incident does occur, it is important to report it promptly. To report a possible violation, **contact Dataparty LLC Managing Members nullagent (https://www.nullagent.com/) or rekcahdam (https://www.rekcahdam.com/)**

Community Moderators take reports of violations seriously and will make every effort to respond in a timely manner. They will investigate all reports of code of conduct violations, reviewing messages, logs, and recordings, or interviewing witnesses and other participants. Community Moderators will keep investigation and enforcement actions as transparent as possible while prioritizing safety and confidentiality. In order to honor these values, enforcement actions are carried out in private with the involved parties, but communicating to the whole community may be part of a mutually agreed upon resolution.


## Addressing and Repairing Harm

**[NOTE: The remedies and repairs outlined below are suggestions based on best practices in code of conduct enforcement. If your community has its own established enforcement process, be sure to edit this section to describe your own policies.]**

If an investigation by the Community Moderators finds that this Code of Conduct has been violated, the following enforcement ladder may be used to determine how best to repair harm, based on the incident's impact on the individuals involved and the community as a whole. Depending on the severity of a violation, lower rungs on the ladder may be skipped.

1) Warning
1) Event: A violation involving a single incident or series of incidents.
2) Consequence: A private, written warning from the Community Moderators.
3) Repair: Examples of repair include a private written apology, acknowledgement of responsibility, and seeking clarification on expectations.
2) Temporarily Limited Activities
1) Event: A repeated incidence of a violation that previously resulted in a warning, or the first incidence of a more serious violation.
2) Consequence: A private, written warning with a time-limited cooldown period designed to underscore the seriousness of the situation and give the community members involved time to process the incident. The cooldown period may be limited to particular communication channels or interactions with particular community members.
3) Repair: Examples of repair may include making an apology, using the cooldown period to reflect on actions and impact, and being thoughtful about re-entering community spaces after the period is over.
3) Temporary Suspension
1) Event: A pattern of repeated violation which the Community Moderators have tried to address with warnings, or a single serious violation.
2) Consequence: A private written warning with conditions for return from suspension. In general, temporary suspensions give the person being suspended time to reflect upon their behavior and possible corrective actions.
3) Repair: Examples of repair include respecting the spirit of the suspension, meeting the specified conditions for return, and being thoughtful about how to reintegrate with the community when the suspension is lifted.
4) Permanent Ban
1) Event: A pattern of repeated code of conduct violations that other steps on the ladder have failed to resolve, or a violation so serious that the Community Moderators determine there is no way to keep the community safe with this person as a member.
2) Consequence: Access to all community spaces, tools, and communication channels is removed. In general, permanent bans should be rarely used, should have strong reasoning behind them, and should only be resorted to if working through other remedies has failed to change the behavior.
3) Repair: There is no possible repair in cases of this severity.

This enforcement ladder is intended as a guideline. It does not limit the ability of Community Managers to use their discretion and judgment, in keeping with the best interests of our community.


## Scope

This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public or other spaces. Examples of representing our community include using an official email address, posting via an official social media account, or acting as an appointed representative at an online or offline event.


## Attribution

This Code of Conduct is adapted from the Contributor Covenant, version 3.0, permanently available at [https://www.contributor-covenant.org/version/3/0/](https://www.contributor-covenant.org/version/3/0/).

Contributor Covenant is stewarded by the Organization for Ethical Source and licensed under CC BY-SA 4.0. To view a copy of this license, visit [https://creativecommons.org/licenses/by-sa/4.0/](https://creativecommons.org/licenses/by-sa/4.0/)

For answers to common questions about Contributor Covenant, see the FAQ at [https://www.contributor-covenant.org/faq](https://www.contributor-covenant.org/faq). Translations are provided at [https://www.contributor-covenant.org/translations](https://www.contributor-covenant.org/translations). Additional enforcement and community guideline resources can be found at [https://www.contributor-covenant.org/resources](https://www.contributor-covenant.org/resources). The enforcement ladder was inspired by the work of [Mozilla’s code of conduct team](https://github.com/mozilla/inclusion).
1 change: 0 additions & 1 deletion examples/secure-config-argon2.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ const HELP_INFO = `
`

async function main(){
const memoryConfig = new Dataparty.Config.MemoryConfig({foo: 'bar'})


const jsonConfig = new Dataparty.Config.JsonFileConfig({
Expand Down
24 changes: 17 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@dataparty/api",
"private": false,
"version": "1.2.25",
"version": "1.3.0",
"main": "dist/dataparty.js",
"frontend": "dist/dataparty-browser.js",
"backend": "dist/dataparty.js",
Expand Down Expand Up @@ -47,6 +47,10 @@
"dist",
"src/*"
],
"bin": {
"venue": "./src/venue/bin/venue.js",
"venued": "./src/venue/bin/venued.js"
},
"scripts": {
"test": "npx lab",
"build": "npx parcel build --no-scope-hoist",
Expand All @@ -63,10 +67,10 @@
},
"dependencies": {
"@babel/runtime": "^7.28.4",
"@dataparty/bouncer-db": "1.0.1",
"@dataparty/bouncer-db": "https://github.com/datapartyjs/bouncer-db#mongoose-latest",
"@dataparty/crypto": "github:datapartyjs/dataparty-crypto",
"@dataparty/tasker": "^0.0.3",
"@diva.exchange/i2p-sam": "^4.1.8",
"@diva.exchange/i2p-sam": "5.5.2",
"@markwylde/liferaft": "^1.3.4",
"@sevenbitbyte/ncc": "0.0.2",
"ajv": "6.12.5",
Expand All @@ -77,18 +81,22 @@
"buffer": "^6.0.3",
"bufferutil": "^4.0.8",
"colors": "1.3.1",
"command-tree": "github:datapartyjs/command-tree",
"cors": "^2.8.5",
"debug": "^3.1.0",
"dom-storage": "^2.1.0",
"eventemitter3": "^4.0.7",
"express": "^4.17.1",
"express-ipfilter": "^1.3.2",
"express-list-routes": "^1.1.9",
"fast-safe-stringify": "^2.1.1",
"find-up-json": "^2.0.5",
"git-repo-info": "^2.1.1",
"joi": "^17.13.3",
"glob": "^13.0.6",
"joi": "^18.2.1",
"joi-objectid": "^4.0.2",
"jshashes": "^1.0.8",
"jsonpath-plus": "^0.20.1",
"jsonpath-plus": "10.4.0",
"last-eventemitter": "^1.1.1",
"lodash": "^4.17.21",
"lokijs": "1.5.12",
Expand All @@ -100,14 +108,15 @@
"node-mocks-http": "^1.12.1",
"node-object-hash": "^3.0.0",
"node-persist": "^3.0.1",
"origin-router": "^1.6.4",
"origin-router": "https://github.com/datapartyjs/origin-router.git",
"parse-url": "^5.0.1",
"promisfy": "^1.2.0",
"roslib": "^1.3.0",
"sanitize-filename": "^1.6.3",
"simple-peer": "9.11.1",
"source-map": "^0.7.3",
"store-js": "^2.0.4",
"tar": "^7.5.15",
"tingodb": "^0.6.1",
"touch": "^3.1.0",
"url-parse": "^1.4.7",
Expand All @@ -118,8 +127,9 @@
"zangodb": "https://github.com/sevenbitbyte/zangodb#hash-patch"
},
"devDependencies": {
"@dataparty/bouncer-model": "1.4.3",
"@dataparty/bouncer-model": "https://github.com/datapartyjs/bouncer-model#mongoose-latest",
"@hapi/code": "^9.0.1",
"@hapi/joi": "^17.1.1",
"@hapi/lab": "^25.0.1",
"argon2": "^0.30.3",
"argon2-browser": "^1.18.0",
Expand Down
6 changes: 6 additions & 0 deletions scripts/install-i2p-ubuntu-24.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash

sudo add-apt-repository ppa:purplei2p/i2pd
sudo apt update
sudo apt install --yes i2pd

7 changes: 5 additions & 2 deletions src/bouncer/db/tingo-db.js
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,13 @@ module.exports = class TingoDb extends IDb {
debug('find collection=', collectionName, ' query=', JSON.stringify(query,null,2))
let collection = await this.getCollection(collectionName)
let cursor = await promisfy(collection.find.bind(collection))(
query,
mongoQuery.hasSort() ? mongoQuery.getSort() : undefined
query
)

if(mongoQuery.hasSort()){
cursor = cursor.sort(mongoQuery.getSort())
}

if(mongoQuery.hasLimit()){
cursor = cursor.limit(mongoQuery.getLimit())
}
Expand Down
2 changes: 1 addition & 1 deletion src/bouncer/ischema.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const debug = require('debug')('bouncer.ISchema')
const debug = require('debug')('dataparty.bouncer.ISchema')
const MgoUtils = require('../utils/mongoose-scheme-utils')

module.exports = class ISchema {
Expand Down
6 changes: 5 additions & 1 deletion src/bouncer/mongo-query.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,11 @@ class MongoQuery {
}

getSort () {
return { [this.spec.sort.param.join('.')]: this.spec.sort.direction }
if(Array.isArray(this.spec.sort.param)){
return { [this.spec.sort.param.join('.')]: this.spec.sort.direction }
}

return { [this.spec.sort.param]: this.spec.sort.direction }
}

/**
Expand Down
1 change: 1 addition & 0 deletions src/comms/isocket-comms.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ class ISocketComms extends EventEmitter {
this.connected = false
debug('Server closed connection')
this.emit('close')
this.emit('server-close')
}

onopen(){
Expand Down
47 changes: 39 additions & 8 deletions src/comms/peer-comms.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ class PeerComms extends ISocketComms {

this.uuid = uuidv4()
this.socket = socket || null
this.stopped = false
this.started = false
//this.auto_reconnect = !socket && !host

this.host = host //! Is comms host\
this.oncall = null
Expand Down Expand Up @@ -89,7 +92,7 @@ class PeerComms extends ISocketComms {

let response = null
let request = await this.decrypt( {data: message}, this.remoteIdentity )
debug('handleHostCall', truncateString(request, 1024))
debug('handleClientCall', truncateString(JSON.stringify(request, null, 2), 1024))

let inputValidated

Expand Down Expand Up @@ -203,11 +206,16 @@ class PeerComms extends ISocketComms {

async start(){
debug('start')

if(this.started){ return }

this.started = true

if(this.socketInit){
await this.socketInit()
}

this.socket.on('close', this.stop.bind(this))
this.socket.on('close', this.socketStop.bind(this))

if(this.host){
debug('host mode comms')
Expand All @@ -226,7 +234,14 @@ class PeerComms extends ISocketComms {
}
}

socketStop(){
debug('socket stop')
this.close()
}

async stop(){
this.stopped = true
this.started = false
debug('stop')
this.close()
}
Expand Down Expand Up @@ -385,13 +400,13 @@ class PeerComms extends ISocketComms {

if(this.party.hostRunner){
const actor = await this.party.hostRunner.auth.lookupIdentity(offer.sender)
const verified = await Routines.verifyDataPQ(actor, signature, offerBSON)
const verified = await Routines.verifyDataPQ(offer.sender, signature, offerBSON)

if(!verified){
throw new Error('DENY(hostRunner) - auth op signature is not valid')
}

if(this.discoverRemoteIdentity){ this.remoteIdentity = actor }
if(this.discoverRemoteIdentity){ this.remoteIdentity = offer.sender }

const authorized = await this.party.hostRunner.auth.isSocketConnectionAllowed(actor)
if(!authorized){
Expand All @@ -406,6 +421,7 @@ class PeerComms extends ISocketComms {
await this.stop()

debug('DENY - client not allowed - ', this.remoteIdentity)
throw new Error('DENY - client not allowed')
}
} else {
const actor = offer.sender
Expand All @@ -420,7 +436,7 @@ class PeerComms extends ISocketComms {
}
}

debug('clienr auth op offer -', offer)
debug('client auth op offer -', offer)
debug('ALLOW - allowing client - ', this.remoteIdentity)

this.aesStream = await AESStream.recoverStream(
Expand All @@ -445,22 +461,34 @@ class PeerComms extends ISocketComms {
async handleCallOp(op){
debug('peer-call', op.input.endpoint)

const actor = await this.party.hostRunner.auth.lookupIdentity(this.remoteIdentity)

if(this.party.hostRunner){

debug('calling runner')

if(op.input.endpoint == 'api-v2-peer-bouncer' && await this.party.hostRunner.auth.isAdmin(this.remoteIdentity)){


if(op.input.endpoint == 'api-v2-peer-bouncer' && await this.party.hostRunner.auth.isAdmin(actor)){
debug('ask->', truncateString(op.input.data, 1024))
op.result = {result: await this.party.handleCall(op.input.data) }

op.setState(HostOp.STATES.Finished_Success)
return
}

debug('input type', typeof op.input.data, Object.keys(op.input.data))
debug('op.msg type', typeof op.msg, Object.keys(op.msg), Buffer.isBuffer(op.msg))

let bodyValue = Buffer.isBuffer(op.msg) ?
op.input.data :
//Routines.BSON.parseObject(new Routines.BSON.BaseParser( op.msg )) :
JSON.parse(op.msg.toString())

const req = HttpMocks.createRequest({
method: 'GET',
url: '/'+op.input.endpoint,
body: (op.input.data) ? JSON.parse(op.msg.toString()) : undefined
body: bodyValue
})

const res = HttpMocks.createResponse()
Expand All @@ -473,6 +501,9 @@ class PeerComms extends ISocketComms {

debug('route',route)

req.peer = this
req.source = 'PeerComms'

debug('call route', await route._events.route({
method: req.method,
pathname: req.url,
Expand All @@ -487,7 +518,7 @@ class PeerComms extends ISocketComms {
op.setState(HostOp.STATES.Finished_Success)
return

} else if(op.input.endpoint == 'api-v2-peer-bouncer' && await this.party.hostRunner.auth.isAdmin(this.remoteIdentity)){
} else if(op.input.endpoint == 'api-v2-peer-bouncer' && await this.party.hostRunner.auth.isAdmin(actor)){

debug('ask->',op.input.data)
op.result = {result: await this.party.handleCall(op.input.data) }
Expand Down
Loading