1,984 karma · joined June 19, 2017
ASN.1X is mostly just a list of additional types, although there is also another serialization format called SDER which is between BER and DER (any valid DER is also valid SDER and any valid SDER is also valid BER), and is intended for when you do not quite need a canonical form but still want the simplicity of DER; one of the things that it allows is overlong length encodings (which is useful when the encoder wants to encode items to a file individually but then go back to encode the length afterward).
The additional types include:
- UTF-16 string: Same as BMP string but non-BMP characters are also allowed (as surrogate pairs). The type number is the same as BMP string.
- OBJECT IDENTIFIER RELATIVE TO: Either a absolute or a relative object identifier; what it is relative to might be either fixed or given elsewhere in the data, depending on the schema. This is equivalent to a type given in the appendix of the official specification of ASN.1, except that it is now a standardized type, and the canonical form (even in SDER, so that a reader does not need to check for both cases) is required to use the relative format if possible.
- BCD string (64): A string of 4-bit characters, with the high nybble first in each byte. The characters come from the character set 0 1 2 3 4 5 6 7 8 9 * # + - . space and it should be padded with a space on the end if necessary.
- PC string (65): A string of characters in the PC character set (or a related character set in some cases). Note that control characters can also be used as graphic characters.
- TRON string (66): A string of TRON characters, encoded as TRON-8.
- Key/value list (67): A set of keys (without duplicates) with associated values. The keys and values can be any type allowed by the schema. In canonical form, they must be sorted by keys in the same order that a SET is sorted (but the values are kept with the corresponding keys). (This is the only one of these nonstandard types which is used for representing JSON data; all of the other JSON types correspond to standard ASN.1 types.)
- Out of band (72): The format and usage of this type depends on the communication channel being used, and is intended for including things inside of the ASN.1X data which is separate from the ASN.1X data, such as file descriptors. This type is not intended for storage in files, and some programs that relay messages may need special handling of this type if it is used (for this reason, it should not be IMPLICIT).
- Reference (74): A reference to another node within the same file (schemas may restrict which nodes can be referenced). The encoding is like a relative OID but the first number is how many times to go to the parent node (0 means the reference itself), and then the rest of the numbers are the zero-based index into the node referenced by the previous number.
- Identified data (75): Contains a set, followed by the payload (of any type), followed by an optional key/value list where the keys are OIDs. The set is used to identify the format, and it can contain OIDs, object descriptors (only expected to be used in error messages and stuff like that), and sequences who first element is a OID; and should not have duplicates. This type may be used as the top-level type in a file in order to identify the file format, but can also be used inside of the file in case the existing types are considered to be insufficient for this purpose.
- Rational number (76): Contains two integers, being the numerator and denominator. The denominator must be greater than zero. If it is canonical form, then it must be lowest terms.
- Translation list (77): A key/value list where the keys specify the languages (null means the default), and is expected to be used where it could be replaced by the appropriate value according to the l10n.
- Scientific number (78): Same as a real number except that the number of digits (or bits) is considered to be significant. Decimal numbers must be NR3, and if it is canonical form then there must be exactly one digit before the dot.
There are also additional situations where the standard ASN.1 schema format does not seem to specify (although as I mentioned above, there is currently no standardized schema format for these things), such as: regular expressions for octet strings (and bit strings), constraining types as though it is another type (e.g. limiting a UTF-8 string to a number of bytes instead of (or in addition to) code points), constraints about what control characters are allowed in a General string (I think it is rarely useful to allow all control characters), etc. (Also, I disagree with the standard recommendation to use automatic tags; I think that manual tags are better and make both the schema and the data files clearer and easier to understand.)
ASN.1 is almost a superset, but lacks a key/value list type; I had made some nonstadard extensions called ASN.1X and one of my new types is a key/value list type, so that makes the data types of ASN.1X a superset of JSON (although the format is different, it makes that all JSON data can be represented using DER if the nonstandard key/value list type of ASN.1X is used).
I don't like JSON that much because of its many problems (some are problems with syntax, others are problems with the data), so I use ASN.1X instead (with the DER format), for my own stuff (but I also deal with JSON because it is common enough).
I have been at one restaurant that had a QR code to view the menu, although they did provide a iPad to any customer who needed it. (At the time, I was with someone else who had their own iPad.) It was not very good food (and badly managed) so I do not intend to return there in future.
If you do not want to print the menu in multiple paper copies, then you might consider a single epaper display somewhere that the customers can easily see (anyone with a camera or a camera phone can take a picture; someone with pencil and paper might copy it out by hand).
Strings passed to system or popen should not be constructed by combining other strings; they should be directly unchanged from whatever trusted source it comes from.
The specific use documented in the article is a situation where I should think that you should not call the shell (since the command includes untrusted input, and also because there might be a better way to display the error message).
There are additional possible security issues with such things though, whether you use the shell or execute directly, some of which are due to the use of text rather than binary data for communication (although changing that won't solve everything).
Doing this with the Accept header is a bad idea, although I think CSS and JavaScripts (in web pages) is not a good solution to this either (they can often make it worse).
My way is the Scorpion conversion file, which must be downloaded explicitly by the end user and the end user must be allowed to override it with their own, and which tells it what to do when it receives a file that it does not recognize, based on the URL or the file type, such as: rewrite the URL, use a uxn program to convert it (to a format that you can use), use a uxn program to display it, etc. Something similar might be possible to add into WWW, by adding a "Interpreter:" response header into HTTP, perhaps using WebAssembly instead of uxn.
However, if another hosting system is done, there some other ideas of some possible things to do:
- Mirroring tickets/discussions as well as the repository (in both directions)
- Support for X.509 client certificate chains for authentication
- Ability to view without JavaScripts and CSS (having JavaScripts and CSS for enhancement is OK, but do not require it and do not add a message to say it is required)
- Support any character sets, including ones not compatible with Unicode (this will not always be displayable in web pages, but will still be usable with some other stuff, such as API using a format other than JSON (e.g. DER))
- Read-only access to public files should not require TLS but should still allow TLS; write access, and access to private files, should require TLS
- A compatible API with GitHub (and possibly others) so that software that works with those API are usable
If there is a broken design of GitHub Actions, that is another issue, and neither TLS nor X.509 is the issue with that. (Also, GitHub Actions could hopefully be made to allow finer permissions if the existing permissions are not fine enough; that is not related to X.509 at all.)
Avoiding too many dependencies, is another thing to do.
And, signed releases is another thing to do, and is helpful for additional reasons (unrelated to authentication with GitHub, but useful for knowing that you published it rather than someone else (without having to trust GitHub with it)). The key used to sign the release might or might not match that in the X.509 certificate used to authenticate with TLS; there are some benefits if it does (such as if you have published your certificates that someone else can check, or your mention of Yubikey), but it doesn't have to (e.g. because you have multiple certificates, because multiple people are publishing releases, because you have some other reason to not use the same certificate for the other purpose, etc).
Additionally, in situations where it would be reasonable, to publish the catalogs including prices and to allow them to be distributed. (My idea of a computer payment file, additionally requires that the catalog file have a proof of work field.)
(If they try to prevent someone from buying them and using them elsewhere or buying one for a specific other person who requested it who they do not know, then that is different, but it might lead to different issues (e.g. liability of tampering with medications, different regulations in different countries, etc).)
I think one thing that would help is to support mutual TLS, with X.509 certificate chains for authentication. This is more secure than personal access tokens and allows you to issue them to yourself and others without needing to login first, including to specify whatever permissions you want to set (as a subset of the permissions of the issuer) and to make them expire. (You could also store the private keys of one certificate on a separate computer not connected to the internet, and use that to issue another one to yourself to use that one instead, and can use a passworded private key as well (an alternative of 2FA), so you can recover even if your certificate you are using does become compromised, or something deletes it (intentionally or not), and can revoke the ones that are compromised.)
Mutual TLS (and even ordinary TLS) won't solve everything, but in combination with other things, including ability to restrict access to what is needed, and avoiding needing too many dependencies (since, programs that need too many dependencies is also one thing that can cause many problems), and many other things, it can be an additional step to help with security.
However, in the case of item 4 of Proposal C, there are multiple kind of "assistance" that is possible; not all of them involve contributing the output of LLMs (e.g. the assistance might be to check for a mistake such as if a paragraph seems to be redundant or is incomplete or something like that; the result from the LLM might be incorrect but you will have to decide by yourself what (if anything) to do about it when writing your message). Even if some kind of assistance should not be banned entirely, it should still be discouraged (like the rest of Proposal C says). (Also, there are other programs that can sometimes be used for the assistance; e.g. sometimes ordinary spelling/grammar checking will do (although that won't find that an incorrect word that is spelled like a correct word in the correct grammar).)
I do not use LLM/generative-AI for any purpose, and would not accept contributions including their output into my projects, and would discourage other uses. (This seems to be similar to Proposal A and Proposal C.)
I think that they should not need to put all of the lights inside and outside even in the day time; the window should be enough light from the sun light (so, they should ensure to have enough window to do that). (You should turn off the light in the night time too so that it is dark in the night time (especially outside).)
(I also made my own implementation of DER, which I already use for some things that are unrelated to X.509, such as a game engine, and some other stuff where a structured data format would be helpful. So, it includes some types which are not used in X.509.)
Some things that it might be possible to help with including, bug reports, feature requests, making a game with it, improvement of documentation if someone finds a problem with it (I think the tutorial document is probably not good enough), etc.
The extensions and plugins should be separated from the rest of the program, like any other extensions, and can be configured and disabled by the end user.
Some of the extensions might come with the distribution, but if so, there should also be another package available which is the same program but without any of the extensions included with it (and should be just as easy to find and use, rather than making it difficult), and also the possibility that if you downloaded it with the extensions it can be disabled, and that if you downloaded it without the extensions then you can still install them like any other extension if wanted.
People who do want the AI features can have them, but not as a core part of the browser (the extension mechanism can be enhanced if it is found to be insufficient, which would help with many other things as well; however, the end users should still be able to control the security features of extensions regardless of who wrote them or where they come from), and possible to get it without those and other potentially unwanted extensions.
Even many official features of WWW may be potentially unwanted; in some cases, these might be made as extensions, and in some cases, they might be made as options which can be configured and disabled. Either way, they should be documented; it is good to have good documentation for any software (and should not require an internet connection to use, even for a web browser).