Commit Graph

  • 7afc61edef UDT: Remove unnecessary and confusing sockShutdown. Elevate linger mode to full listen/send mode, which is necessary to combat the shutdown message race condition. Close #47 close #45 Kleissner 2021-10-25 09:12:33 +02:00
  • 0c80eb2e3d UDT: Fix ddos in ackEvent. It sets ackTimerEvent which triggers ackEvent ... an endless loop. ackTimerEvent is actually not needed at all. Kleissner 2021-10-25 08:42:24 +02:00
  • 1ec20e6386 UDT: Fix critical bug in multiplexer.goWrite. It was overwriting packets on the fly. A new buffer is needed for each outgoing packet. Kleissner 2021-10-25 07:56:35 +02:00
  • a8592e9975 Fix #46: Transfer receive data function must be started in go routine since it is blocking. Kleissner 2021-10-25 06:10:12 +02:00
  • 2984dc6b79 UDT: Fix another critical bug. udtSocketRecv.farNextPktSeq was not incremented. Note: The open bug #43 is still pending, although it will give a warning now. The warning can be used as debugging point. Kleissner 2021-10-25 04:50:40 +02:00
  • 2df8dba4fe UDT: Temporary bush fix for buggy code #43. Packet loss is currently ignored, but at least it works now. The function udtSocketRecv.sendNAK is an endless loop and needs a rewrite. Kleissner 2021-10-25 04:12:44 +02:00
  • 57450e506f UDT: Fix another critical new bug in getRcvSpeeds. CC #43 Kleissner 2021-10-25 04:05:53 +02:00
  • b0d71c2dc7 UDT: Fix critical bug in reevalSendState Kleissner 2021-10-25 03:42:04 +02:00
  • b5266b1c52 File Transfer: Add header to file transfer to indicate file size and transfer size. This is important to know when to stop reading. It will also help when reading only ranges (which is important for video streaming). New function FileTransferReadHeaderUDT to read the header. Warehouse: ReadFile return count bytes read Kleissner 2021-10-25 03:34:28 +02:00
  • 39bc255007 Minor cleanup Kleissner 2021-10-24 06:31:36 +02:00
  • f6bbd02a01 Transfer: Change virtual connection from net.PacketConn to channels which is faster and less complex. Improve termination behavior and documentation of it. Kleissner 2021-10-24 06:27:23 +02:00
  • 153ca78ed7 UDT: Removing MTU in favor of MaxPacketSize. Kleissner 2021-10-24 04:59:14 +02:00
  • 75e3d9a42e Initial UDT implementation for file transfer. New function RequestFileTransferUDT to download files from other peers. Kleissner 2021-10-24 04:26:30 +02:00
  • 6c2d526251 Protocol sequences: Add support for bidirectional responses. Kleissner 2021-10-24 02:28:33 +02:00
  • 7b732e1232 Create initial virtual net.PacketConn code for embedding other transfer protocols. This is likely going to be replaced with direct channel I/O. Create swarm readme! Swarms are to be introduced soon! Kleissner 2021-10-24 00:18:04 +02:00
  • 789d177052 New function sendTransfer Kleissner 2021-10-23 06:53:34 +02:00
  • f1e30c942f webapi: /blockchain/file/add and /blockchain/file/update now always overwrite file size field. Update file now fails if ID is not provided. Kleissner 2021-10-22 16:55:03 +02:00
  • 0c4562e1d3 Protocol: Fixes in Transfer code. Add IsLast convenience functions. Kleissner 2021-10-22 06:23:56 +02:00
  • 89f9e3a563 New function PublicKeyFromPeerID Kleissner 2021-10-22 06:17:28 +02:00
  • 2659921cb8 warehouse: Minor refactoring. Use native hash encoding for FileExists. Kleissner 2021-10-22 00:21:59 +02:00
  • c7b9facc10 webapi: /search/result always return stats if requested Kleissner 2021-10-21 16:18:20 +02:00
  • d2899a4378 Initial Transfer message encoding. Embedded UDT implementation to follow. Documentation of file transfer to follow in upcoming Whitepaper update. Kleissner 2021-10-20 10:20:56 +02:00
  • fb9944aaed Update readme Kleissner 2021-10-20 09:00:33 +02:00
  • e45d6fe888 New function to delete account. Create deletion functions for blockchain and warehouse. Add function /account/delete to webapi. Close #42 Kleissner 2021-10-20 08:46:53 +02:00
  • 285bed59e3 webapi: Document time zone behavior. Kleissner 2021-10-19 17:36:18 +02:00
  • f954c4777b Refactor message encoding code into separate files. No code changes. Kleissner 2021-10-18 04:57:54 +02:00
  • c9d9be2972 Refactor message encoding into protocol package. User Agent must be now provided in the Init function. Kleissner 2021-10-18 04:37:02 +02:00
  • f1e8e0cab8 Finally moving Sequence code into protocol package Kleissner 2021-10-18 02:41:55 +02:00
  • 5d93a74981 Collecting network vars and functions in networks structure Kleissner 2021-10-18 02:12:36 +02:00
  • e2542b3a4d Create struct ipList from ip listening list Kleissner 2021-10-18 01:10:40 +02:00
  • 1b9151d6fd Refactor sequence code into SequenceManager Kleissner 2021-10-17 21:34:30 +02:00
  • 767181620e Prepare refactoring of sequence code Kleissner 2021-10-17 20:02:35 +02:00
  • be7b596551 Rename field sequence in MessageRaw due to name collision in PacketRaw Kleissner 2021-10-17 19:42:19 +02:00
  • 77579a8866 Simplify EncodeAnnouncement. Return generic packetsRaw. Fixes also a theoretical bug in announcement encoding for multicast/broadcast. Kleissner 2021-10-17 19:30:24 +02:00
  • b51579fb3f Untangle function IsBadQuality Kleissner 2021-10-17 18:29:21 +02:00
  • 42ff6d926e Change msgNewSequence function to use parameters Kleissner 2021-10-17 17:53:48 +02:00
  • 1b93eac17a Moving FeatureSupport() and UserBlockchain.Header() calls out of Message Encoding. This paves the way for refactoring the message code into the protocol package. Kleissner 2021-10-17 17:40:22 +02:00
  • 4d3caaf567 Move message sending code into separate file (no code changes) Kleissner 2021-10-17 17:20:21 +02:00
  • 7be31a9e34 Refactoring code. Use protocol.HashData and HashSize. Move PublicKey2NodeID into protocol. Kleissner 2021-10-17 17:15:22 +02:00
  • 39217ab5ef Untangle connection parameters from msgEncodeTraverseSetAddress Kleissner 2021-10-17 16:55:31 +02:00
  • 93f10fd3b5 Untangle connection from MessageRaw, paving the way for refactoring the message code into the protocol package. Kleissner 2021-10-17 16:39:41 +02:00
  • 0c7b1e0e03 Start refactoring protocol code into sub package. Move Packet Encoding and list of Commands. Change SetSelfReportedPorts parameters. More related commits to follow! Kleissner 2021-10-17 16:28:19 +02:00
  • 2476146949 Add info about other UPnP packages Kleissner 2021-10-16 13:32:43 +02:00
  • 0dc383e767 Moving blockchain code into separate files (no code changes). Kleissner 2021-10-14 02:40:28 +02:00
  • e78ca02af7 Housekeeping! Renaming /blockchain functions for simplicity Kleissner 2021-10-13 22:26:30 +02:00
  • 1c0406dc60 Housekeeping! Removing unnecessary "blockchain" prefix of status codes within the blockchain package. Kleissner 2021-10-13 21:22:17 +02:00
  • b556acb86c webapi: New function /blockchain/file/update blockchain: Add readme.md. Add function ReplaceFiles. Kleissner 2021-10-13 20:09:09 +02:00
  • 336de68801 Refactor blockchain code into separate files (no code changes). Kleissner 2021-10-13 15:30:35 +02:00
  • c2f110169a Automatically delete files from Warehouse in case there are no other references when deleting files from the blockchain via /blockchain/self/delete/file. New function blockchain.FileExists. blockchain.DeleteFiles now returns list of deleted files. Kleissner 2021-10-13 06:00:40 +02:00
  • 335f83d79b /blockchain/self/add/file checks now if the file exists in the Warehouse and aborts with StatusCorruptBlockRecord if not. Kleissner 2021-10-13 02:42:04 +02:00
  • cec070b740 Introducing Warehouse - the store for files shared by the user. Kleissner 2021-10-13 01:40:58 +02:00
  • 956e6dd76b Sync reuseport sub-package to latest version Kleissner 2021-10-11 01:38:13 +02:00
  • fbeb01e7ff Major refactoring of blockchain code into new sub-package. Kleissner 2021-10-11 01:21:38 +02:00
  • 7495b823e4 webapi search: Implement /search/result/ws Kleissner 2021-10-10 16:58:09 +02:00
  • 7891bdbeac webapi search: Provide option to embed statistics into /search/result response Kleissner 2021-10-10 16:07:44 +02:00
  • 4ef002ab57 webapi: Add /search/statistic Kleissner 2021-10-10 15:32:29 +02:00
  • 7c3fc8938f webapi search: Add min/max file size as filter. Kleissner 2021-10-10 03:03:35 +02:00
  • 5707132687 webapi: Search: Add support for additional sorting parameters (Size ASC/DESC, Shared by count ASC/DESC). Kleissner 2021-10-10 02:20:36 +02:00
  • 2451fdafb1 New Search Job code. Supports filtering and sorting. Renaming apiBlockRecordFile -> apiFile. Added filters and sort parameters to /search/result. Improved API documentation. Added documentation about search filters and sort parameter. Kleissner 2021-10-05 10:50:04 +02:00
  • b79b0d2194 Moving File API code into separate file Kleissner 2021-10-05 08:06:07 +02:00
  • 72787044d2 Finished dummy download API. Kleissner 2021-10-04 07:23:19 +02:00
  • 958ec52f83 Close #18 cmdResponseBootstrapFindSelf uses now a recently-contacted list to prevent potential initial flood when multiple peers return the same peer for FIND_SELF. Kleissner 2021-10-01 00:33:43 +02:00
  • d29fc960b6 Add file metadata TagSharedByCount and TagSharedByGeoIP Kleissner 2021-09-29 20:20:53 +02:00
  • 2c20fa950d Add node ID field to file structure Kleissner 2021-09-28 19:55:30 +02:00
  • 608dbf6f47 Simplified profile code. Kleissner 2021-09-28 05:39:38 +02:00
  • 9ef6a88512 Reworked the way metadata/tags for files work. Simplified it at lot. Kleissner 2021-09-28 02:59:47 +02:00
  • 24df8c1eb0 webapi: Add dummy /download/start and /download/status endpoints Kleissner 2021-09-27 03:49:34 +02:00
  • dc093f5f6d webapi: Add file type and format detection via /file/format Kleissner 2021-09-26 23:40:22 +02:00
  • 3fbb1a824b Add special type -2 to /explore. Kleissner 2021-09-25 13:09:40 +02:00
  • 175f1fb438 Fix race condition in FindNode Kleissner 2021-09-24 13:45:12 +02:00
  • 7e402de278 webapi: New endpoint /explore to list recently shared files, currently dummy data Kleissner 2021-09-23 23:53:44 +02:00
  • 58b4603744 Initial search API with dummy results Kleissner 2021-09-23 02:32:07 +02:00
  • edc14925c7 Improve documentation Kleissner 2021-09-20 14:45:33 +02:00
  • 149984eeb3 webapi: New endpoint /profile/delete Kleissner 2021-09-20 14:20:23 +02:00
  • 680723faf3 Blockchain: New function UserProfileDelete to delete user profile data. Kleissner 2021-09-20 14:19:04 +02:00
  • df0f57063f Add endpoint /blockchain/self/delete/file to delete files. Kleissner 2021-09-19 00:57:49 +02:00
  • 06b846ca34 Blockchain functions: Return version number. Add record deletion and refactoring function. Allow to delete files. Kleissner 2021-09-19 00:01:31 +02:00
  • 67bf27a4af Refactor apiTest into Status.go Kleissner 2021-09-15 16:29:26 +02:00
  • 16e9c0e67f Add TypeEbook. Clarify documentation on File Type and File Format. Kleissner 2021-09-15 16:25:09 +02:00
  • 95640fede3 webapi: Export EncodeJSON, DecodeJSON Kleissner 2021-09-10 19:19:06 +02:00
  • 3f3e6d9df1 Add date field to apiBlockRecordFile Kleissner 2021-09-10 14:43:01 +02:00
  • 19e29b3a91 Add webapi. Provides an HTTP API for clients to use Peernet. Kleissner 2021-09-10 13:40:07 +02:00
  • 928c16c492 New profile functions to read/write profile fields and blobs Kleissner 2021-09-03 02:24:26 +02:00
  • 22f21d187a Add virtual tag TagTypeDateShared. Kleissner 2021-08-28 13:37:38 +02:00
  • a3750af1c8 Fix bug correct block number Kleissner 2021-08-28 13:26:06 +02:00
  • 7c88763f28 Minor fix when creating new blockchain, initializing used public key Kleissner 2021-08-27 17:38:36 +02:00
  • 20399f121b Rewrite of profile records on blockchain. This allows to add/update profile data (including future fields and blobs) at any time. Kleissner 2021-08-27 06:15:37 +02:00
  • 8fb9afaddc Rename Directory to Folder to make more sense. Introduce new file type TypeFolder which is not used anywhere, however. Kleissner 2021-08-27 04:58:15 +02:00
  • a2384ca627 Blockchain: Change of block format. File records: * Add unique ID to file record. * Introducing tags which are flexible. Close #31 * Name and Directory fields are now tags. * Embedded basic compression by storing duplicate file tags as single record. Added date field to record structure. Kleissner 2021-08-27 03:12:30 +02:00
  • ea80588fa1 Add format field to the blockchain header. This allows backward compatibility. Close #32 Kleissner 2021-08-25 01:13:00 +02:00
  • 6c399a7be9 New function UserBlockchainListFiles to list all files in the users blockchain. Refactor block record decoding code. Kleissner 2021-08-19 16:49:37 +02:00
  • a2420b8468 Store user blockchain data in file. Close #30 Refactoring sanitize code into separate sub-package Refactoring block and block record decoding code Kleissner 2021-08-19 04:13:08 +02:00
  • 7c7048c4c7 Use Pogreb as key/value store instead for now. Kleissner 2021-08-11 22:49:00 +02:00
  • 5d01fc6c72 Initial code to read/create the users blockchain database on the file system. Kleissner 2021-08-11 22:36:47 +02:00
  • afef726aaf Add tentatively cockroachdb/pebble as initial database! This can be changed/replaced easily. Unfortunately it adds 7 MB to the binary and tons of dependencies :( Kleissner 2021-08-11 22:18:30 +02:00
  • 3da1acde60 Key/value database rename functions. Kleissner 2021-08-11 22:16:39 +02:00
  • d87e43cd32 Simplify Store interface. Remove unused replication placeholder and untangle expiration option. MemoryStore is refactored into separate file. Kleissner 2021-08-11 20:15:22 +02:00
  • 2937154c8d Add filters for low-level packet and high-level message interception for debugging purposes. Close #4 Kleissner 2021-07-31 17:29:14 +02:00
  • dc54f94351 Fix in sendInfoRequest Kleissner 2021-07-29 04:41:18 +02:00
  • 3233bf5c1b New Filters.IncomingRequest to intercept incoming information requests of all types Kleissner 2021-07-29 04:10:53 +02:00