Update intro and cbor quick start in README (#421)
Update README for v2.5.0 * Rewrite Quick Start * Update intro to show Struct Tags and CBOR Security earlier. * Removed sections: "Comparison", "Usage", "Why fxamacker/cbor", "CBOR Options", "API", etc. * Removed files: CBOR_GOLANG.md, CBOR_BENCHMARKS.md, etc. * Update CODE_OF_CONDUCT.md * Add openssf scorecard badge but did not link to detailed report. * Make Acknowledgements section placeholder because new contributors weren't included for years.
This commit is contained in:
parent
66971779ea
commit
837230c62b
@ -1,264 +0,0 @@
|
||||
# CBOR Benchmarks for fxamacker/cbor
|
||||
|
||||
See [bench_test.go](bench_test.go).
|
||||
|
||||
Benchmarks on Feb. 22, 2020 with cbor v2.2.0:
|
||||
* [Go builtin types](#go-builtin-types)
|
||||
* [Go structs](#go-structs)
|
||||
* [Go structs with "keyasint" struct tag](#go-structs-with-keyasint-struct-tag)
|
||||
* [Go structs with "toarray" struct tag](#go-structs-with-toarray-struct-tag)
|
||||
* [COSE data](#cose-data)
|
||||
* [CWT claims data](#cwt-claims-data)
|
||||
* [SenML data](#SenML-data)
|
||||
|
||||
## Go builtin types
|
||||
|
||||
Benchmarks use data representing the following values:
|
||||
|
||||
* Boolean: `true`
|
||||
* Positive integer: `18446744073709551615`
|
||||
* Negative integer: `-1000`
|
||||
* Float: `-4.1`
|
||||
* Byte string: `h'0102030405060708090a0b0c0d0e0f101112131415161718191a'`
|
||||
* Text string: `"The quick brown fox jumps over the lazy dog"`
|
||||
* Array: `[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26]`
|
||||
* Map: `{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}}`
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshal/CBOR_bool_to_Go_interface_{}-2 | 110 ns/op | 16 B/op | 1 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_bool_to_Go_bool-2 | 99.3 ns/op | 1 B/op | 1 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_positive_int_to_Go_interface_{}-2 | 135 ns/op | 24 B/op | 2 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_positive_int_to_Go_uint64-2 | 116 ns/op | 8 B/op | 1 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_negative_int_to_Go_interface_{}-2 | 133 ns/op | 24 B/op | 2 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_negative_int_to_Go_int64-2 | 113 ns/op | 8 B/op | 1 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_float_to_Go_interface_{}-2 | 137 ns/op | 24 B/op | 2 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_float_to_Go_float64-2 | 115 ns/op | 8 B/op | 1 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_bytes_to_Go_interface_{}-2 | 179 ns/op | 80 B/op | 3 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_bytes_to_Go_[]uint8-2 | 194 ns/op | 64 B/op | 2 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_text_to_Go_interface_{}-2 | 209 ns/op | 80 B/op | 3 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_text_to_Go_string-2 | 193 ns/op | 64 B/op | 2 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_array_to_Go_interface_{}-2 |1068 ns/op | 672 B/op | 29 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_array_to_Go_[]int-2 | 1073 ns/op | 272 B/op | 3 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_interface_{}-2 | 2926 ns/op | 1420 B/op | 30 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_map[string]interface_{}-2 | 3755 ns/op | 965 B/op | 19 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_map[string]string-2 | 2586 ns/op | 740 B/op | 5 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshal/Go_bool_to_CBOR_bool-2 | 86.1 ns/op | 1 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_uint64_to_CBOR_positive_int-2 | 97.0 ns/op | 16 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_int64_to_CBOR_negative_int-2 | 90.3 ns/op | 3 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_float64_to_CBOR_float-2 | 97.9 ns/op | 16 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_[]uint8_to_CBOR_bytes-2 | 121 ns/op | 32 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_string_to_CBOR_text-2 | 115 ns/op | 48 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_[]int_to_CBOR_array-2 | 529 ns/op | 32 B/op | 1 allocs/op
|
||||
BenchmarkMarshal/Go_map[string]string_to_CBOR_map-2 | 2115 ns/op | 576 B/op | 28 allocs/op
|
||||
|
||||
## Go structs
|
||||
|
||||
Benchmarks use struct and map[string]interface{} representing the following value:
|
||||
|
||||
```
|
||||
{
|
||||
"T": true,
|
||||
"Ui": uint(18446744073709551615),
|
||||
"I": -1000,
|
||||
"F": -4.1,
|
||||
"B": []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
"S": "The quick brown fox jumps over the lazy dog",
|
||||
"Slci": []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
"Mss": map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"},
|
||||
}
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_map[string]interface{}-2 | 6221 ns/op | 2621 B/op | 73 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_struct-2 | 4458 ns/op | 1172 B/op | 10 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshal/Go_map[string]interface{}_to_CBOR_map-2 | 4441 ns/op | 1072 B/op | 45 allocs/op
|
||||
BenchmarkMarshal/Go_struct_to_CBOR_map-2 | 2866 ns/op | 720 B/op | 28 allocs/op
|
||||
|
||||
## Go structs with "keyasint" struct tag
|
||||
|
||||
Benchmarks use struct (with keyasint struct tag) and map[int]interface{} representing the following value:
|
||||
|
||||
```
|
||||
{
|
||||
1: true,
|
||||
2: uint(18446744073709551615),
|
||||
3: -1000,
|
||||
4: -4.1,
|
||||
5: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
6: "The quick brown fox jumps over the lazy dog",
|
||||
7: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
8: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"},
|
||||
}
|
||||
```
|
||||
|
||||
Struct type with keyasint struct tag is used to handle CBOR map with integer keys.
|
||||
|
||||
```
|
||||
type T struct {
|
||||
T bool `cbor:"1,keyasint"`
|
||||
Ui uint `cbor:"2,keyasint"`
|
||||
I int `cbor:"3,keyasint"`
|
||||
F float64 `cbor:"4,keyasint"`
|
||||
B []byte `cbor:"5,keyasint"`
|
||||
S string `cbor:"6,keyasint"`
|
||||
Slci []int `cbor:"7,keyasint"`
|
||||
Mss map[string]string `cbor:"8,keyasint"`
|
||||
}
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_map[int]interface{}-2| 6030 ns/op | 2517 B/op | 70 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_map_to_Go_struct_keyasint-2 | 4332 ns/op | 1173 B/op | 10 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshal/Go_map[int]interface{}_to_CBOR_map-2 | 4348 ns/op | 992 B/op | 45 allocs/op
|
||||
BenchmarkMarshal/Go_struct_keyasint_to_CBOR_map-2 | 2847 ns/op | 704 B/op | 28 allocs/op
|
||||
|
||||
## Go structs with "toarray" struct tag
|
||||
|
||||
Benchmarks use struct (with toarray struct tag) and []interface{} representing the following value:
|
||||
|
||||
```
|
||||
[
|
||||
true,
|
||||
uint(18446744073709551615),
|
||||
-1000,
|
||||
-4.1,
|
||||
[]byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
"The quick brown fox jumps over the lazy dog",
|
||||
[]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26},
|
||||
map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}
|
||||
]
|
||||
```
|
||||
|
||||
Struct type with toarray struct tag is used to handle CBOR array.
|
||||
|
||||
```
|
||||
type T struct {
|
||||
_ struct{} `cbor:",toarray"`
|
||||
T bool
|
||||
Ui uint
|
||||
I int
|
||||
F float64
|
||||
B []byte
|
||||
S string
|
||||
Slci []int
|
||||
Mss map[string]string
|
||||
}
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshal/CBOR_array_to_Go_[]interface{}-2 | 4863 ns/op | 2404 B/op | 67 allocs/op
|
||||
BenchmarkUnmarshal/CBOR_array_to_Go_struct_toarray-2 | 4173 ns/op | 1164 B/op | 9 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshal/Go_[]interface{}_to_CBOR_map-2 | 3240 ns/op | 704 B/op | 28 allocs/op
|
||||
BenchmarkMarshal/Go_struct_toarray_to_CBOR_array-2 | 2823 ns/op | 704 B/op | 28 allocs/op
|
||||
|
||||
## COSE data
|
||||
|
||||
Benchmarks use COSE data from https://tools.ietf.org/html/rfc8392#appendix-A section A.2
|
||||
|
||||
```
|
||||
// 128-Bit Symmetric COSE_Key
|
||||
{
|
||||
/ k / -1: h'231f4c4d4d3051fdc2ec0a3851d5b383'
|
||||
/ kty / 1: 4 / Symmetric /,
|
||||
/ kid / 2: h'53796d6d6574726963313238' / 'Symmetric128' /,
|
||||
/ alg / 3: 10 / AES-CCM-16-64-128 /
|
||||
}
|
||||
// 256-Bit Symmetric COSE_Key
|
||||
{
|
||||
/ k / -1: h'403697de87af64611c1d32a05dab0fe1fcb715a86ab435f1
|
||||
ec99192d79569388'
|
||||
/ kty / 1: 4 / Symmetric /,
|
||||
/ kid / 4: h'53796d6d6574726963323536' / 'Symmetric256' /,
|
||||
/ alg / 3: 4 / HMAC 256/64 /
|
||||
}
|
||||
// ECDSA 256-Bit COSE Key
|
||||
{
|
||||
/ d / -4: h'6c1382765aec5358f117733d281c1c7bdc39884d04a45a1e
|
||||
6c67c858bc206c19',
|
||||
/ y / -3: h'60f7f1a780d8a783bfb7a2dd6b2796e8128dbbcef9d3d168
|
||||
db9529971a36e7b9',
|
||||
/ x / -2: h'143329cce7868e416927599cf65a34f3ce2ffda55a7eca69
|
||||
ed8919a394d42f0f',
|
||||
/ crv / -1: 1 / P-256 /,
|
||||
/ kty / 1: 2 / EC2 /,
|
||||
/ kid / 2: h'4173796d6d657472696345434453413
|
||||
23536' / 'AsymmetricECDSA256' /,
|
||||
/ alg / 3: -7 / ECDSA 256 /
|
||||
}
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshalCOSE/128-Bit_Symmetric_Key-2 | 562 ns/op | 240 B/op | 4 allocs/op
|
||||
BenchmarkUnmarshalCOSE/256-Bit_Symmetric_Key-2 | 568 ns/op | 256 B/op | 4 allocs/op
|
||||
BenchmarkUnmarshalCOSE/ECDSA_P256_256-Bit_Key-2 | 968 ns/op | 360 B/op | 7 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshalCOSE/128-Bit_Symmetric_Key-2 | 523 ns/op | 224 B/op | 2 allocs/op
|
||||
BenchmarkMarshalCOSE/256-Bit_Symmetric_Key-2 | 521 ns/op | 240 B/op | 2 allocs/op
|
||||
BenchmarkMarshalCOSE/ECDSA_P256_256-Bit_Key-2 | 668 ns/op | 320 B/op | 2 allocs/op
|
||||
|
||||
## CWT claims data
|
||||
|
||||
Benchmarks use CTW claims data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1
|
||||
|
||||
```
|
||||
{
|
||||
/ iss / 1: "coap://as.example.com",
|
||||
/ sub / 2: "erikw",
|
||||
/ aud / 3: "coap://light.example.com",
|
||||
/ exp / 4: 1444064944,
|
||||
/ nbf / 5: 1443944944,
|
||||
/ iat / 6: 1443944944,
|
||||
/ cti / 7: h'0b71'
|
||||
}
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshalCWTClaims-2 | 765 ns/op | 176 B/op | 6 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshalCWTClaims-2 | 451 ns/op | 176 B/op | 2 allocs/op
|
||||
|
||||
## SenML data
|
||||
|
||||
Benchmarks use SenML data from https://tools.ietf.org/html/rfc8428#section-6
|
||||
|
||||
```
|
||||
[
|
||||
{-2: "urn:dev:ow:10e2073a0108006:", -3: 1276020076.001, -4: "A", -1: 5, 0: "voltage", 1: "V", 2: 120.1},
|
||||
{0: "current", 6: -5, 2: 1.2},
|
||||
{0: "current", 6: -4, 2: 1.3},
|
||||
{0: "current", 6: -3, 2: 1.4},
|
||||
{0: "current", 6: -2, 2: 1.5},
|
||||
{0: "current", 6: -1, 2: 1.6},
|
||||
{0: "current", 6: 0, 2: 1.7}
|
||||
]
|
||||
```
|
||||
|
||||
Decoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkUnmarshalSenML-2 | 3106 ns/op | 1544 B/op | 18 allocs/op
|
||||
|
||||
Encoding Benchmark | Time | Memory | Allocs
|
||||
--- | ---: | ---: | ---:
|
||||
BenchmarkMarshalSenML-2 | 2976 ns/op | 272 B/op | 2 allocs/op
|
||||
@ -1,32 +0,0 @@
|
||||
👉 [Comparisons](https://github.com/fxamacker/cbor#comparisons) • [Status](https://github.com/fxamacker/cbor#current-status) • [Design Goals](https://github.com/fxamacker/cbor#design-goals) • [Features](https://github.com/fxamacker/cbor#features) • [Standards](https://github.com/fxamacker/cbor#standards) • [Fuzzing](https://github.com/fxamacker/cbor#fuzzing-and-code-coverage) • [Usage](https://github.com/fxamacker/cbor#usage) • [Security Policy](https://github.com/fxamacker/cbor#security-policy) • [License](https://github.com/fxamacker/cbor#license)
|
||||
|
||||
# CBOR
|
||||
[CBOR](https://en.wikipedia.org/wiki/CBOR) is a data format designed to allow small code size and small message size. CBOR is defined in [RFC 8949 Concise Binary Object Representation](https://tools.ietf.org/html/rfc8949) (previously [RFC 7049](https://tools.ietf.org/html/rfc7049)), an [IETF](http://ietf.org/) Internet Standards Document.
|
||||
|
||||
CBOR is also designed to be stable for decades, be extensible without need for version negotiation, and not require a schema.
|
||||
|
||||
While JSON uses text, CBOR uses binary. CDDL can be used to express CBOR (and JSON) in an easy and unambiguous way. CDDL is defined in (RFC 8610 Concise Data Definition Language).
|
||||
|
||||
## CBOR in Golang (Go)
|
||||
[Golang](https://golang.org/) is a nickname for the Go programming language. Go is specified in [The Go Programming Language Specification](https://golang.org/ref/spec).
|
||||
|
||||
__[fxamacker/cbor](https://github.com/fxamacker/cbor)__ is a library (written in Go) that encodes and decodes CBOR. The API design of fxamacker/cbor is based on Go's [`encoding/json`](https://golang.org/pkg/encoding/json/). The design and reliability of fxamacker/cbor makes it ideal for encoding and decoding COSE.
|
||||
|
||||
## COSE
|
||||
COSE is a protocol using CBOR for basic security services. COSE is defined in ([RFC 8152 CBOR Object Signing and Encryption](https://tools.ietf.org/html/rfc8152)).
|
||||
|
||||
COSE describes how to create and process signatures, message authentication codes, and encryption using CBOR for serialization. COSE specification also describes how to represent cryptographic keys using CBOR. COSE is used by WebAuthn.
|
||||
|
||||
## CWT
|
||||
CBOR Web Token (CWT) is defined in [RFC 8392](http://tools.ietf.org/html/rfc8392). CWT is based on COSE and was derived in part from JSON Web Token (JWT). CWT is a compact way to securely represent claims to be transferred between two parties.
|
||||
|
||||
## WebAuthn
|
||||
[WebAuthn](https://en.wikipedia.org/wiki/WebAuthn) (Web Authentication) is a web standard for authenticating users to web-based apps and services. It's a core component of FIDO2, the successor of FIDO U2F legacy protocol.
|
||||
|
||||
__[fxamacker/webauthn](https://github.com/fxamacker/webauthn)__ is a library (written in Go) that performs server-side authentication for clients using FIDO2 keys, legacy FIDO U2F keys, tpm, and etc.
|
||||
|
||||
Copyright (c) Faye Amacker and contributors.
|
||||
|
||||
<hr>
|
||||
|
||||
👉 [Comparisons](https://github.com/fxamacker/cbor#comparisons) • [Status](https://github.com/fxamacker/cbor#current-status) • [Design Goals](https://github.com/fxamacker/cbor#design-goals) • [Features](https://github.com/fxamacker/cbor#features) • [Standards](https://github.com/fxamacker/cbor#standards) • [Fuzzing](https://github.com/fxamacker/cbor#fuzzing-and-code-coverage) • [Usage](https://github.com/fxamacker/cbor#usage) • [Security Policy](https://github.com/fxamacker/cbor#security-policy) • [License](https://github.com/fxamacker/cbor#license)
|
||||
@ -1,76 +1,133 @@
|
||||
|
||||
# Contributor Covenant Code of Conduct
|
||||
|
||||
## Our Pledge
|
||||
|
||||
In the interest of fostering an open and welcoming environment, we as
|
||||
contributors and maintainers pledge to making participation in our project and
|
||||
our community a harassment-free experience for everyone, regardless of age, body
|
||||
size, disability, ethnicity, sex characteristics, gender identity and expression,
|
||||
level of experience, education, socio-economic status, nationality, personal
|
||||
appearance, race, religion, or sexual identity and orientation.
|
||||
We as members, contributors, and leaders pledge to make participation in our
|
||||
community a harassment-free experience for everyone, regardless of age, body
|
||||
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
||||
identity and expression, level of experience, education, socio-economic status,
|
||||
nationality, personal appearance, race, caste, color, religion, or sexual
|
||||
identity and orientation.
|
||||
|
||||
We pledge to act and interact in ways that contribute to an open, welcoming,
|
||||
diverse, inclusive, and healthy community.
|
||||
|
||||
## Our Standards
|
||||
|
||||
Examples of behavior that contributes to creating a positive environment
|
||||
include:
|
||||
Examples of behavior that contributes to a positive environment for our
|
||||
community include:
|
||||
|
||||
* Using welcoming and inclusive language
|
||||
* Being respectful of differing viewpoints and experiences
|
||||
* Gracefully accepting constructive criticism
|
||||
* Focusing on what is best for the community
|
||||
* Showing empathy towards other community members
|
||||
* Demonstrating empathy and kindness toward other people
|
||||
* Being respectful of differing opinions, viewpoints, and experiences
|
||||
* Giving and gracefully accepting constructive feedback
|
||||
* Accepting responsibility and apologizing to those affected by our mistakes,
|
||||
and learning from the experience
|
||||
* Focusing on what is best not just for us as individuals, but for the overall
|
||||
community
|
||||
|
||||
Examples of unacceptable behavior by participants include:
|
||||
Examples of unacceptable behavior include:
|
||||
|
||||
* The use of sexualized language or imagery and unwelcome sexual attention or
|
||||
advances
|
||||
* Trolling, insulting/derogatory comments, and personal or political attacks
|
||||
* The use of sexualized language or imagery, and sexual attention or advances of
|
||||
any kind
|
||||
* Trolling, insulting or derogatory comments, and personal or political attacks
|
||||
* Public or private harassment
|
||||
* Publishing others' private information, such as a physical or electronic
|
||||
address, without explicit permission
|
||||
* Publishing others' private information, such as a physical or email address,
|
||||
without their explicit permission
|
||||
* Other conduct which could reasonably be considered inappropriate in a
|
||||
professional setting
|
||||
professional setting
|
||||
|
||||
## Our Responsibilities
|
||||
## Enforcement Responsibilities
|
||||
|
||||
Project maintainers are responsible for clarifying the standards of acceptable
|
||||
behavior and are expected to take appropriate and fair corrective action in
|
||||
response to any instances of unacceptable behavior.
|
||||
Community leaders are responsible for clarifying and enforcing our standards of
|
||||
acceptable behavior and will take appropriate and fair corrective action in
|
||||
response to any behavior that they deem inappropriate, threatening, offensive,
|
||||
or harmful.
|
||||
|
||||
Project maintainers have the right and responsibility to remove, edit, or
|
||||
reject comments, commits, code, wiki edits, issues, and other contributions
|
||||
that are not aligned to this Code of Conduct, or to ban temporarily or
|
||||
permanently any contributor for other behaviors that they deem inappropriate,
|
||||
threatening, offensive, or harmful.
|
||||
Community leaders have the right and responsibility to remove, edit, or reject
|
||||
comments, commits, code, wiki edits, issues, and other contributions that are
|
||||
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
||||
decisions when appropriate.
|
||||
|
||||
## Scope
|
||||
|
||||
This Code of Conduct applies both within project spaces and in public spaces
|
||||
when an individual is representing the project or its community. Examples of
|
||||
representing a project or community include using an official project e-mail
|
||||
address, posting via an official social media account, or acting as an appointed
|
||||
representative at an online or offline event. Representation of a project may be
|
||||
further defined and clarified by project maintainers.
|
||||
This Code of Conduct applies within all community spaces, and also applies when
|
||||
an individual is officially representing the community in public spaces.
|
||||
Examples of representing our community include using an official e-mail address,
|
||||
posting via an official social media account, or acting as an appointed
|
||||
representative at an online or offline event.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||
reported by contacting the project team at faye.github@gmail.com. All
|
||||
complaints will be reviewed and investigated and will result in a response that
|
||||
is deemed necessary and appropriate to the circumstances. The project team is
|
||||
obligated to maintain confidentiality with regard to the reporter of an incident.
|
||||
Further details of specific enforcement policies may be posted separately.
|
||||
reported to the community leaders responsible for enforcement at
|
||||
faye.github@gmail.com.
|
||||
All complaints will be reviewed and investigated promptly and fairly.
|
||||
|
||||
Project maintainers who do not follow or enforce the Code of Conduct in good
|
||||
faith may face temporary or permanent repercussions as determined by other
|
||||
members of the project's leadership.
|
||||
All community leaders are obligated to respect the privacy and security of the
|
||||
reporter of any incident.
|
||||
|
||||
## Enforcement Guidelines
|
||||
|
||||
Community leaders will follow these Community Impact Guidelines in determining
|
||||
the consequences for any action they deem in violation of this Code of Conduct:
|
||||
|
||||
### 1. Correction
|
||||
|
||||
**Community Impact**: Use of inappropriate language or other behavior deemed
|
||||
unprofessional or unwelcome in the community.
|
||||
|
||||
**Consequence**: A private, written warning from community leaders, providing
|
||||
clarity around the nature of the violation and an explanation of why the
|
||||
behavior was inappropriate. A public apology may be requested.
|
||||
|
||||
### 2. Warning
|
||||
|
||||
**Community Impact**: A violation through a single incident or series of
|
||||
actions.
|
||||
|
||||
**Consequence**: A warning with consequences for continued behavior. No
|
||||
interaction with the people involved, including unsolicited interaction with
|
||||
those enforcing the Code of Conduct, for a specified period of time. This
|
||||
includes avoiding interactions in community spaces as well as external channels
|
||||
like social media. Violating these terms may lead to a temporary or permanent
|
||||
ban.
|
||||
|
||||
### 3. Temporary Ban
|
||||
|
||||
**Community Impact**: A serious violation of community standards, including
|
||||
sustained inappropriate behavior.
|
||||
|
||||
**Consequence**: A temporary ban from any sort of interaction or public
|
||||
communication with the community for a specified period of time. No public or
|
||||
private interaction with the people involved, including unsolicited interaction
|
||||
with those enforcing the Code of Conduct, is allowed during this period.
|
||||
Violating these terms may lead to a permanent ban.
|
||||
|
||||
### 4. Permanent Ban
|
||||
|
||||
**Community Impact**: Demonstrating a pattern of violation of community
|
||||
standards, including sustained inappropriate behavior, harassment of an
|
||||
individual, or aggression toward or disparagement of classes of individuals.
|
||||
|
||||
**Consequence**: A permanent ban from any sort of public interaction within the
|
||||
community.
|
||||
|
||||
## Attribution
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
||||
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
||||
version 2.1, available at
|
||||
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
|
||||
|
||||
Community Impact Guidelines were inspired by
|
||||
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
|
||||
|
||||
For answers to common questions about this code of conduct, see the FAQ at
|
||||
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
|
||||
[https://www.contributor-covenant.org/translations][translations].
|
||||
|
||||
[homepage]: https://www.contributor-covenant.org
|
||||
|
||||
For answers to common questions about this code of conduct, see
|
||||
https://www.contributor-covenant.org/faq
|
||||
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
|
||||
[Mozilla CoC]: https://github.com/mozilla/diversity
|
||||
[FAQ]: https://www.contributor-covenant.org/faq
|
||||
[translations]: https://www.contributor-covenant.org/translations
|
||||
|
||||
Loading…
Reference in New Issue
Block a user