Discriminator

Last updated

In computing, a discriminator is a field of characters designed to separate a certain element from others of the same identifier. This has been adopted by programming languages as well as digital platforms for instant messaging and massively multiplayer online games.

Contents

In instant messaging

A discriminator is used to disambiguate a user from other users who wish to identify under the same username.

Discord

On Discord, a discriminator is a four-digit suffix added to the end of a username. This allowed for up to 9,999 user accounts to take the same name.

Transition away from discriminators

In 2023, co-founder Stanislav Vishnevskiy wrote on a company blog post about the technical debt caused by the discriminator system, stating that the system resulted in nearly half of the company's friend requests failing to connect. The platform implemented discriminators in the early days of the service, he wrote. When the platform was initially introduced, the software developers' priority was to let its users take any username they want without receiving a “your desired username is taken” error. Discord had no friend system at first, thus letting people take names in different letter cases, making usernames case-sensitive. [1]

Discord also introduced a global display name system, wherein a user may input a default nickname to be shown on top of the messages they sent in lieu of their platformwide username, Vishnevskiy touted on Reddit. [2]

The platform created a transition process to a system of pseudonyms wherein all new usernames would be case-insensitive lowercase and limited to the ASCII characters of A–Z, 0–9, the full stop and the underscore. The transition would happen over the course of months, with the accounts that were registered the oldest, and paid subscribers, receiving the opportunity to reserve their name earlier.

This change was criticized online for being a step backward, as users could be a risk of being impersonated. A notable indie game studio noted that it could no longer claim its own name on the platform. [3] Discord pointed to its processes for users with high visibility and longstanding business relationships with the company for reserving a username under the new system. The old discriminator-oriented system also mitigated the rush to get unique usernames for sale on the black market, leading to swatting and online harassment. [4] [2]

In digital distribution

Battle.net implements a suffix of four-digit numbers to its usernames.

In computer data storage

Common Object Request Broker Architecture

A discriminator is a typed tag field present in the Common Object Request Broker Architecture, the interface description language of the Object Management Group. It exists as type and value definitions of tagged unions that determine which union member is selected in the current union instance. This is done by introduction of the classic C switch construct as part of the classic C union. [5] [6] Unlike in some conventional programming languages offering support for unions, the discriminator in IDL is not identical to the selected field name. Here is an example of an IDL union type definition:

unionRegisterswitch(char){case'a':case'b':shortAX;case'c':longEAX;default:octetAL;};

The effective value of the Register type may contain AX as the selected field, but the discriminator value may be either 'a' or 'b' and is stored in memory separately. Therefore, IDL logically separates information about the currently selected field name and the union effective value from information about the current discriminator value. In the example above, the discriminator value may be any of the following: 'a', 'b', 'c', as well as all other characters belonging to the IDL char type, since the default branch specified in the example Register type allows the use of the remaining characters as well.

Other interface definition languages

The Microsoft Interface Definition Language also supports tagged unions, allowing to choose the discriminator via an attribute in an enclosing structure or function. [7]

Alternatives

A friend code is a unique twelve-digit number that could be exchanged with friends and be used to maintain individual friend lists in each video game. Friend codes were generated from an identifier unique to a copy of a game and the universally unique identifier corresponding to that of a user's device. [8]

Related Research Articles

The Common Object Request Broker Architecture (CORBA) is a standard defined by the Object Management Group (OMG) designed to facilitate the communication of systems that are deployed on diverse platforms. CORBA enables collaboration between systems on different operating systems, programming languages, and computing hardware. CORBA uses an object-oriented model although the systems that use the CORBA do not have to be object-oriented. CORBA is an example of the distributed object paradigm.

In computers, case sensitivity defines whether uppercase and lowercase letters are treated as distinct (case-sensitive) or equivalent (case-insensitive). For instance, when users interested in learning about dogs search an e-book, "dog" and "Dog" are of the same significance to them. Thus, they request a case-insensitive search. But when they search an online encyclopedia for information about the United Nations, for example, or something with no ambiguity regarding capitalization and ambiguity between two or more terms cut down by capitalization, they may prefer a case-sensitive search.

The File Transfer Protocol (FTP) is a standard communication protocol used for the transfer of computer files from a server to a client on a computer network. FTP is built on a client–server model architecture using separate control and data connections between the client and the server. FTP users may authenticate themselves with a clear-text sign-in protocol, normally in the form of a username and password, but can connect anonymously if the server is configured to allow it. For secure transmission that protects the username and password, and encrypts the content, FTP is often secured with SSL/TLS (FTPS) or replaced with SSH File Transfer Protocol (SFTP).

An interface description language or interface definition language (IDL), is a generic term for a language that lets a program or object written in one language communicate with another program written in an unknown language. IDLs describe an interface in a language-independent way, enabling communication between software components that do not share one language, for example, between those written in C++ and those written in Java.

<span class="mw-page-title-main">Universally unique identifier</span> Label used for information in computer systems

A Universally Unique IDentifier (UUID) is a 128-bit label used for information in computer systems. The term Globally Unique IDentifier (GUID) is also used, mostly in Microsoft systems.

<span class="mw-page-title-main">Filename</span> Text string used to uniquely identify a computer file

A filename or file name is a name used to uniquely identify a computer file in a file system. Different file systems impose different restrictions on filename lengths.

In computer science, a tagged union, also called a variant, variant record, choice type, discriminated union, disjoint union, sum type or coproduct, is a data structure used to hold a value that could take on several different, but fixed, types. Only one of the types can be in use at any one time, and a tag field explicitly indicates which one is in use. It can be thought of as a type that has several "cases", each of which should be handled correctly when that type is manipulated. This is critical in defining recursive datatypes, in which some component of a value may have the same type as that value, for example in defining a type for representing trees, where it is necessary to distinguish multi-node subtrees and leaves. Like ordinary unions, tagged unions can save storage by overlapping storage areas for each type, since only one is in use at a time.

In distributed computing, General Inter-ORB Protocol (GIOP) is the message protocol by which object request brokers (ORBs) communicate in CORBA. Standards associated with the protocol are maintained by the Object Management Group (OMG). The current version of GIOP is 2.0.2. The GIOP architecture provides several concrete protocols, including:

  1. Internet InterORB Protocol (IIOP) — The Internet Inter-Orb Protocol is an implementation of the GIOP for use over the Internet, and provides a mapping between GIOP messages and the TCP/IP layer.
  2. SSL InterORB Protocol (SSLIOP) — SSLIOP is IIOP over SSL, providing encryption and authentication.
  3. HyperText InterORB Protocol (HTIOP) — HTIOP is IIOP over HTTP, providing transparent proxy bypassing.
  4. Zipped InterORB Protocol (ZIOP) — A zipped version of GIOP that reduces the bandwidth usage
passwd Tool to change passwords on Unix-like OSes

passwd is a command on Unix, Plan 9, Inferno, and most Unix-like operating systems used to change a user's password. The password entered by the user is run through a key derivation function to create a hashed version of the new password, which is saved. Only the hashed version is stored; the entered password is not saved for security reasons.

This article compares two programming languages: C# with Java. While the focus of this article is mainly the languages and their features, such a comparison will necessarily also consider some features of platforms and libraries. For a more detailed comparison of the platforms, see Comparison of the Java and .NET platforms.

The Data Distribution Service (DDS) for real-time systems is an Object Management Group (OMG) machine-to-machine standard that aims to enable dependable, high-performance, interoperable, real-time, scalable data exchanges using a publish–subscribe pattern.

RMI-IIOP denotes the Java Remote Method Invocation (RMI) interface over the Internet Inter-Orb Protocol (IIOP), which delivers Common Object Request Broker Architecture (CORBA) distributed computing capabilities to the Java platform. It was initially based on two specifications: the Java Language Mapping to OMG IDL, and CORBA/IIOP 2.3.1.

In the context of the Microsoft Windows NT line of operating systems, a Security Identifier (SID) is a unique, immutable identifier of a user, user group, or other security principal. A security principal has a single SID for life, and all properties of the principal, including its name, are associated with the SID. This design allows a principal to be renamed without affecting the security attributes of objects that refer to the principal.

<span class="mw-page-title-main">User (computing)</span> Person who uses a computer or network service

A user is a person who utilizes a computer or network service.

Component Object Model (COM) is a binary-interface standard for software components introduced by Microsoft in 1993. It is used to enable inter-process communication object creation in a large range of programming languages. COM is the basis for several other Microsoft technologies and frameworks, including OLE, OLE Automation, Browser Helper Object, ActiveX, COM+, DCOM, the Windows shell, DirectX, UMDF and Windows Runtime. The essence of COM is a language-neutral way of implementing objects that can be used in environments different from the one in which they were created, even across machine boundaries. For well-authored components, COM allows reuse of objects with no knowledge of their internal implementation, as it forces component implementers to provide well-defined interfaces that are separated from the implementation. The different allocation semantics of languages are accommodated by making objects responsible for their own creation and destruction through reference-counting. Type conversion casting between different interfaces of an object is achieved through the QueryInterface method. The preferred method of "inheritance" within COM is the creation of sub-objects to which method "calls" are delegated.

A file format is a standard way that information is encoded for storage in a computer file. It specifies how bits are used to encode information in a digital storage medium. File formats may be either proprietary or free.

OTP is a collection of useful middleware, libraries, and tools written in the Erlang programming language. It is an integral part of the open-source distribution of Erlang. The name OTP was originally an acronym for Open Telecom Platform, which was a branding attempt before Ericsson released Erlang/OTP as open source. However neither Erlang nor OTP is specific to telecom applications.

<span class="mw-page-title-main">Rust (programming language)</span> General-purpose programming language

Rust is a multi-paradigm, general-purpose programming language that emphasizes performance, type safety, and concurrency. It enforces memory safety—ensuring that all references point to valid memory—without requiring the use of a garbage collector or reference counting present in other memory-safe languages. To simultaneously enforce memory safety and prevent concurrent data races, its "borrow checker" tracks the object lifetime of all references in a program during compilation. Rust borrows ideas from functional programming, including static types, immutability, higher-order functions, and algebraic data types. It is popularized for systems programming.

<span class="mw-page-title-main">BeerXML</span> Markup language

BeerXML is a free, fully defined XML data description standard designed for the exchange of beer brewing recipes and other brewing data. Tables of recipes as well as other records such as hop schedules and malt bills can be represented using BeerXML for use by brewing software.

<span class="mw-page-title-main">Discord</span> Online communication software

Discord is an American VoIP and instant messaging social platform. Users have the ability to communicate with voice calls, video calls, text messaging, media and files in private chats or as part of communities called "servers". A server is a collection of persistent chat rooms and voice channels which can be accessed via invite links. Discord runs on Windows, macOS, Android, iOS, iPadOS, Linux, and in web browsers. As of 2021, the service has over 350 million registered users and over 150 million monthly active users. It is primarily used by gamers, although the share of other users is growing.

References

  1. Mehrotra, Shikhar (May 7, 2023). "Discord's New Usernames: Everything You Need To Know About The Update". Screen Rant. Retrieved June 12, 2023.
  2. 1 2 Shakir, Umar (May 6, 2023). "Discord's username change is causing discord". The Verge . Vox Media . Retrieved June 12, 2023.
  3. Wright, Steven (May 22, 2023). "Discord's Controversial New Policy Has Prevented A Dev From Claiming Its Own Name". GameSpot . Fandom, Inc. Retrieved June 12, 2023.
  4. Gerken, Tom (May 4, 2023). "Discord plans to make everyone change their username". BBC News. British Broadcasting Company . Retrieved June 12, 2023.
  5. Object Management Group (March 12, 2004). "CORBA/IIOP Specification 3.0.3". OMG.org. Archived from the original on October 15, 2007.
  6. "CORBA 3.0 - IDL Syntax and Semantics chapter". OMG.org. March 12, 2004.
  7. "Microsoft discriminator attribute documentation". Microsoft Learn. October 25, 2019.
  8. Studdard, Kim (April 19, 2023). "How to Add Friends on Nintendo Switch: In 5 Easy Steps With Photos" . Retrieved June 12, 2023 via MSN.