| .. | ||
| abstract_anonymous_networks.docx | ||
| abstract_anonymous_networks.pdf | ||
| decentralized_key_exchange_protocol.docx | ||
| decentralized_key_exchange_protocol.pdf | ||
| general_theory_of_anonymous_communications.pdf | ||
| grok_anonymity.pdf | ||
| grok_anonymity.pptx | ||
| hidden_lake_anonymous_network.pdf | ||
| hidden_lake_anonymous_network.pptx | ||
| hidden_lake_message_layers.svg | ||
| monolithic_cryptographic_protocol.docx | ||
| monolithic_cryptographic_protocol.pdf | ||
| README.md | ||
| theory_of_the_structure_of_hidden_systems.docx | ||
| theory_of_the_structure_of_hidden_systems.pdf | ||
Docs
Theoretical works
1. Main
- Theory of the structure of hidden systems
- Monolithic cryptographic protocol
- Abstract anonymous networks
- Decentralized key exchange protocol
Also, the composition of these works can be found in the book The general theory of anonymous communications. This book can be purchased in a tangible form on the Ozon and Wildberries marketplaces. You can download the book in digital form for free here.
2. Presentations
3. Habr
- Hidden Lake Service
- Hidden Lake Messenger
- Hidden Lake Traffic
- Hidden Lake Adapters
- Micro-Anonymous Network
- Entropy Increase Networks
- Create node in the Hidden Lake
4. Videos
Default applications ports
- HLS = 957x
- HLT = 958x
- HLM = 959x
- HLL = 956x
- HLE = 955x
- HLF = 954x
- HL_T = 950x
Code style go-peer
In the course of editing the project, some code styles may be added, some edited. Therefore, the current state of the project may not fully adhere to the code style, but you need to strive for it.
1. Prefixes
The name of the global constants must begin with the prefix 'c' or 'C'.
const (
cInternalConst = 1
CExternalConst = 2
)
The name of the global variables must begin with the prefix 'g' or 'G'. The exception is errors with the prefix 'err' or 'Err'.
var (
gInternalVariable = 1
GExternalVariable = 2
)
The name of the global structs must begin with the prefix 's' or 'S'. Also fields in the structure must begin with the prefix 'f' or 'F'.
type (
sInternalStruct struct{
fInternalField int
}
SExternalStruct struct{
FExternalField int
}
)
The name of the global interfaces must begin with the prefix 'i' or 'I'. Also type functions must begin with the prefix 'i' or 'I'.
type (
iInternalInterface interface{}
IExternalInterface interface{}
)
type (
iInternalFunc func()
iExternalFunc func()
)
The name of the function parameters must begin with the prefix 'p' or 'P'. Also method's object must be equal 'p'. The exception of this code style is test files.
func f(pK, pV int) {}
func (p *sObject) m() {}
The name of the global constants, variables, structures, fields, interfaces in the test environment must begin with prefix 't' or 'T'.
const (
tcInternalConst = 1
TcExternalConst = 2
)
var (
tgInternalVariable = 1
TgExternalVariable = 2
)
type (
tsInternalStruct struct{
tfInternalField int
}
TsExternalStruct struct{
TfInternalField int
}
)
type (
tiInternalInterface interface{}
TiExternalInterface interface{}
)
type (
tiInternalFunc func()
TiExternalFunc func()
)
2. Function / Methods names
Functions and methods should consist of two parts, where the first is a verb, the second is a noun. Standart names: Get, Set, Add, Del and etc. Example
type IClient interface {
GetIndex() (string, error)
GetPubKey() (asymmetric.IPubKey, error)
SetPrivKey(asymmetric.IPrivKey) error
GetOnlines() ([]string, error)
DelOnline(string) error
GetFriends() (map[string]asymmetric.IPubKey, error)
AddFriend(string, asymmetric.IPubKey) error
DelFriend(string) error
GetConnections() ([]string, error)
AddConnection(string) error
DelConnection(string) error
BroadcastRequest(asymmetric.IPubKey, request.IRequest) error
FetchRequest(asymmetric.IPubKey, request.IRequest) ([]byte, error)
}
3. If blocks
The following is allowed.
if err := f(); err != nil {
// ...
}
err := g(
a,
b,
c,
)
if err != nil {
// ...
}
The following is not allowed.
if v {
// ...
} else { /* eradicate the 'else' block */
// ...
}
err := f() /* may be in if block */
if err != nil {
// ...
}
if err := g(
a,
b,
c,
); err != nil { /* not allowed multiply line-args in if block */
// ...
}
4. Interface declaration
When a type is bound to an interface, it must be explicitly specified like this.
var (
_ types.IRunner = &sApp{}
)
5. Calling functions/methods
External simple getter functions/methods should not be used inside the package.
func (p *sObject) GetSettings() ISettings {
return p.fSettings
}
func (p *sObject) GetValue() IValue {
p.fMutex.Lock()
defer p.fMutex.Unlock()
return p.fValue
}
...
func (p *sObject) DoSomething() {
_ = p.fSettings // correct
_ = p.GetSettings() // incorrect
// incorrect
p.fMutex.Lock()
_ = p.fValue
p.fMutex.Unlock()
_ = p.GetValue() // correct
}
6. Args/Returns interfaces
It is not allowed to use global structures in function arguments or when returning. Interfaces should be used instead of structures.
The following is allowed.
func doObject(_ IObject) {}
func newObject() IObject {}
The following is not allowed.
func doObject(_ *SObject) {}
func newObject() *SObject {}