Andrew Bettison
56cb12f507
Refactor rhizome db creation and execution functions
2012-06-12 18:12:36 +09:30
Andrew Bettison
637ef02f30
Add _selfsigned column to "rhizome list" output
...
Add <pin,pin...> arg1 to "rhizome list" command, so it can open the keyring
Some tests in tests/rhizome fail
2012-06-08 18:25:43 +09:30
Andrew Bettison
7a71a521f8
Pass author SID parameters in binary, not hex
2012-06-08 15:27:15 +09:30
Andrew Bettison
86c7819f97
Remove spurious ERROR messsages
...
Tests assert that stderr contains no ERROR: lines after a successful exit
Rewrote sqlite_exec_int64() to separate error outcomes from legitimate
result values
Changed several WHY() calls to DEBUG()
Improved test framework
2012-06-08 13:13:26 +09:30
Andrew Bettison
a9ad1b6afc
Add <bsk> optional arg to "rhizome add file"
...
Improve regular expressions for common data types in test scripts
Revert column count field delimiter in "rhizome list" from ":" to "\n"
Add a few more test cases
2012-06-05 13:58:59 +09:30
Andrew Bettison
304db6e5f4
Fix SEGV bug in "rhizome extract file" command
...
Add optional <key> argument, validate and parse it properly.
2012-06-01 18:12:59 +09:30
gardners
2aaea99bfa
added function for computing bundle shared secret, e.g., for
...
MeshMS encryption. Currently just returns NULL (no encryption),
and not yet hooked in.
2012-05-28 13:51:24 +02:00
Jeremy Lakeman
36389d2b78
Insert manifest within a transaction
2012-05-28 14:08:01 +09:30
gardners
30e53f963c
fixed various manifest synchronisation bugs, including probably
...
the main one that was stopping meshms (large manifests would
practically never get advertised under certain (common) conditions).
2012-05-27 08:31:48 +02:00
gardners
94d17a9260
more work on encrypting bundles. code passes all 23 rhizome tests.
2012-05-26 11:36:19 +02:00
gardners
58cc45043b
added code to encrypt files when storing into the database.
2012-05-26 11:36:19 +02:00
gardners
2de6bb025a
rhizome_extract_file can now decrypt a file, and also uses
...
progressive blob operations so that we can extract files of
unlimited size.
2012-05-26 11:36:19 +02:00
gardners
04cc05d6e1
refactored manifest verification into a separate function
...
that is called only when needed, and marks a manifest as finalised
if the verifcation fails. reading a manifest now never sets
finalised flag, as either _finalise() or _verify() must be called.
2012-05-26 11:36:18 +02:00
gardners
e213a9eae8
renamed sanity_check to check_sanity for consistency.
...
Put missing check for illegal service type into check_sanity.
2012-05-26 11:36:18 +02:00
gardners
8161709c4e
work on fixing handling of duplicate rhizome bundle debouncing.
...
(seems to work from command line, but not from the test framework).
2012-05-26 11:36:18 +02:00
gardners
b0dca7e03f
merged in latest changes from team.
2012-05-26 11:36:18 +02:00
Andrew Bettison
d215d90b40
Refactored some rhizome db SQL code
...
Added sqlite_exec_void() function, so that sqlite_exec_int64() can return
an error if no rows are found instead of 0, which can be misleading.
2012-05-25 19:42:45 +09:30
Andrew Bettison
bea9188cd5
Fix another manifest leak
...
Add manifest alloc/free debug logging to help, 'debug.manifests' option
2012-05-25 17:01:56 +09:30
Andrew Bettison
49aec4d331
Improve rhizome manifest debugging
...
Move rhizome_new_manifest() out of rhizome_read_manifest_file() so that the
out-of-manifest report shows the names of the functions where the manifests
were really allocated.
2012-05-25 15:38:13 +09:30
Andrew Bettison
c0ac693957
Remove old payload when updating a manifest with a new payload
2012-05-25 14:29:55 +09:30
Andrew Bettison
fa26b53294
Fix SEGV bug
...
rhizome_write_manifest_file() was not checking for NULL fopen() result
Standardise rhizome "import" directory pathname handling
2012-05-24 11:28:32 +09:30
Andrew Bettison
1af9125392
All rhizome database keys are uppercase hex
...
FILES.id, MANIFESTS.id, FILEMANIFESTS.fileid, FILEMANIFESTS.manifestid
Named constants for hex and binary ID sizes
2012-05-23 16:04:00 +09:30
gardners
e3387fbecf
periodic sucking in from rhizome prioritised list now works.
2012-05-22 15:57:18 +09:30
gardners
f528110257
almost have priority pre-listing of bundles for rhizome working.
2012-05-22 15:57:18 +09:30
gardners
0abc7ff96e
added code to create and maintain priority download list for
...
rhizome, so that we get things in a sensible order.
2012-05-22 15:57:18 +09:30
gardners
8e9396419c
adding ignored manifest list to let us ignore repeated offerings
...
of broken manifests without wasting effort.
2012-05-22 14:15:35 +09:30
gardners
29bb86d9e7
first cut at supressing rhizome activity during calls.
2012-05-22 13:05:29 +09:30
Andrew Bettison
e6575cb369
Introduce macro constants for Rhizome service names
...
Use "MeshMS1" instead of "MeshMS"... version 2 won't be far away
2012-05-20 16:07:22 +09:30
Andrew Bettison
33f7ea7103
Add three optional args to "rhizome list" command
...
service, sender_sid, recipient_sid - not yet implemented
2012-05-16 13:47:58 +09:30
gardners
0eafc34970
BK encoding and decoding complete, but untested.
2012-05-15 20:04:41 +09:30
gardners
525d3c4154
substantial work towards implementing BK field in rhizome manifests.
2012-05-15 17:24:25 +09:30
Andrew Bettison
f90b21ec78
Implement rhizome config options
...
rhizome.datastore_path - if not set, reverts to serval instance path
rhizome.enable - if not set, defaults to true
2012-05-15 12:56:10 +09:30
Andrew Bettison
b02e9b9ac4
Overhaul rhizome datastore path code
...
Create datastore directory and all parent dirs if it does not exist
More robust error checking and buffer overflow protection
New mkdirs() and mkdirsn() functions
2012-05-14 18:37:32 +09:30
gardners
0b5a9665b2
first cut code for sending monitor socket announcements when
...
rhizome bundles are received.
2012-05-12 07:24:52 +09:30
Andrew Bettison
7ba15ccdd7
Add "rhizome extract file" command with tests
2012-05-02 17:57:35 +09:30
Andrew Bettison
146eb7cdfd
Add "rhizome extract manifest" command
2012-05-02 16:03:09 +09:30
Andrew Bettison
a73916e85a
Implement JNI command-line interface (untested)
...
- argv is (const char *const *) everywhere, to avoid having to strdup() all the
Java arg strings
- changed (char*) to (const char*) in lots of places to fix cascading compiler
warnings as a result of argv constness
- fixed a bug in "config get" command when used without 'variable' arg
2012-04-23 17:18:15 +09:30
Andrew Bettison
de88d3db21
Make "dna rhizome add" work for more test cases
...
- adding a bundle using an existing manifest with an incorrect payload should
fail with an error
- adding a bundle using an existing manifest to update the payload to a new
version should succeed
- improve format of "dna rhizome list" output to one bundle per line
2012-04-13 18:03:19 +09:30
Andrew Bettison
7b53fd6782
Rhizome add does not add duplicate files
...
- If a bundle has the same payload hash and manifest.name as one already in
the rhizome store, then the "dna rhizome add" command will not add it
- Now passes fourth test case in tests/dna_rhizome
2012-04-12 18:33:43 +09:30
Andrew Bettison
f52db7f406
Fix bugs revealed by rhizome "add manifest" test case
2012-04-10 18:13:05 +09:30
Andrew Bettison
74986a0c30
Implement "rhizome add file" and "rhizome list"
2012-04-02 17:42:40 +09:30
Daniel O'Connor
a8411edf3f
- Use system wide sqlite3 lib via pkg-config
...
- Remove nacl-gcc-prep, it's now in nacl
- Sort sources and have 1 per line.
- Add missing source files.
- Use naclinc.txt and nacllib.txt generated by nacl/nacl-gcc-prep
- Update ignore file now nacl files don't pollute this directory.
2012-02-27 12:41:48 +10:30
gardners
8a24fb95b1
Converted manifest storage to using static set of manifest structures
...
and added manifest leak detection and some other memory corruption
protections.
2012-01-28 11:45:45 +10:30
gardners
45e8d68522
Added a manifest:version cache to avoid database lookups when being
...
offered manifests, thus saving cpu/energy.
2012-01-27 17:11:18 +10:30
gardners
c0676fd530
Fixed various bugs and memory leaks in rhizome file fetching.
...
Now successfully fetches manifests for files we already have in
the database, using the existing database copy of the file.
Also added filter to stop same file being fetched more than once at
same time..
2012-01-27 16:21:48 +10:30
gardners
cdf1c45da4
Rhizome fetching over http now receives files and imports them.
...
Still some wrinkles to work out.
2012-01-13 21:13:17 +10:30
gardners
f862ba0af6
Rhizome file transfer via http getting close
...
(send side needs to send file body)
2012-01-13 17:21:06 +10:30
gardners
bf9f8559f1
Various debug fiddles and conversion from select() to poll()
...
(although poll() still doesn't let us monitor ordinary files
which is silly.)
2012-01-12 16:47:24 +10:30
gardners
42b5c08321
Refactored rhizome.c into several smaller files.
...
Manifests are now gleaned from advertisements, and the ones that
are interesting are scheduled for importing into database.
(actual importing is not yet done -- requires fetching of file).
2012-01-12 14:05:05 +10:30
gardners
4e6ef2e69e
Various fixes to Rhizome web server and BAR generation.
...
Can now present a set of BARs via HTTP.
2012-01-03 16:35:02 +10:30