Introduction to Operational Amplifiers in Electronic Circuits
A simple electronic circuit uses few components, but complex circuits are difficult to design. Integrated Circuits (ICs) overcome these challenges by incorporating multiple components on a single chip. Advantages of ICs include compact size, reduced weight, low power consumption, cost-effectiveness, increased reliability, and improved operating speeds. They can be analog or digital, with analog ICs further categorized into linear types. Learn more about the benefits and types of Integrated Circuits in this informative chapter.
Download Presentation

Please find below an Image/Link to download the presentation.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.
You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.
E N D
Presentation Transcript
Election Algorithms Many distributed algorithms require one process to act as coordinator, initiator, etc. No matter which process takes the role Election needed when the special process down An election algorithm selects the special process and ensure all processes agree 3/17/2025 Yong Chen, Texas Tech University 1
The Bully Algorithm (1) The Bully Algorithm 1. P (with noticing coordinator down) sends an ELECTION message to all processes with higher numbers. 2. If no one responds, P wins the election and becomes coordinator. 3. If one of the higher-ups answers, it takes over. P s job is done. 3/17/2025 2
The Bully Algorithm (2) The bully election algorithm. (a) Process 4 holds an election. (b) Processes 5 and 6 respond, telling 4 to stop. (c) Now 5 and 6 each hold an election. 3/17/2025 3
The Bully Algorithm (3) Figure 6-20. The bully election algorithm. (d) Process 6 tells 5 to stop. (e) Process 6 wins and tells everyone. 3/17/2025 4
The Bully Algorithm (4) Analysis How many messages in the worst case? Worst case: When the process with lowest id in the system detects the failure Number of election messages: (n-1)+(n-2)+ +2+1 = n*n/2 = 0(n2) How many messages in the best case? Best case: Second highest id detects leader failure Number of election messages: ??? Number of OK messages: Number of coordinator messages:
The Bully Algorithm: Example 2 3/17/2025 6
A Ring Algorithm (1) Assuming processes logically ordered in a ring and each process knows this virtual topology (i.e each process s successor) (unidirectional) When any process notices the coordinator not functioning, it builds an ELECTION message with its own process number and circulates At each step a sender adds its process number and skips any process not responding At the end (the initiating process sees its own process number), the process with highest number elected as the new coordinator and a COORDINATOR msg circulated 3/17/2025 Yong Chen, Texas Tech University 7
A Ring Algorithm (2) Election algorithm using a ring. 3/17/2025 8
The Ring Algorithm Analysis How many messages in the worst case? How many messages in the best case?
Next topics Security: Important and difficult principle in distributed systems Deals with unknowns Cryptography Symmetric cryptosystems Asymmetric cryptosystems 3/17/2025 Yong Chen, Texas Tech University 10
Security Focus on two main parts Secure communication (between users or processes) Secure channels, authentication, integrity, confidentiality Authorization (between processes and resources) Access rights, access control 3/17/2025 Yong Chen, Texas Tech University 11
Security Threats (1) From a security perspective, computer systems have three general goals 3/17/2025 Yong Chen, Texas Tech University 12
Security Threats (2) Types of security threats to consider: Interception Unauthorized party gains access to a service or data Interruption Makes service or data unavailable, corrupted or lost Modification Unauthorized changing of data or tampering a service Fabrication Additional data or activity generated Threats caused by intruders (passive/active intruders) 3/17/2025 Yong Chen, Texas Tech University 13
Security Policies and Mechanisms (1) A security policy describes precisely which actions the entities in a system are allowed to take and which ones are prohibited Entities include users, services, data, machines, and so on Security mechanisms are actions taken to ensure/enforce the security policy 3/17/2025 Yong Chen, Texas Tech University 14
Security Policies and Mechanisms (2) Security mechanisms 1. Encryption Transforms data into a form an attacker can t understand 2. Authentication Verify the claimed identity of a user, client, server, host Two factor authentication: AWS cloud 3. Authorization Authorize entities to perform actions requested 4. Auditing Tracing activities for analysis of a security breach 3/17/2025 Yong Chen, Texas Tech University 15
Outline Questions? Security threats, policies, and mechanisms Cryptography Symmetric cryptosystems Asymmetric cryptosystems Secure channels 3/17/2025 Yong Chen, Texas Tech University 16
Cryptography (1) A fundamental mechanism to achieve security A sender encrypts a message m into m and send to a receiver, which decrypts into original m Ciphertext: C = EK(P) Plaintext: P = DK(C) Keys: K 3/17/2025 Yong Chen, Texas Tech University 17
Cryptography (2) Protection from Attacks Figure 9-6. Intruders and eavesdroppers in communication. 3/17/2025 Yong Chen, Texas Tech University 18
Cryptography (3) Symmetric cryptosystem: same key to encrypt/decrypt (secret-key/shared-key systems) P = DK(EK(P)) Asymmetric cryptosystem: keys different and form a unique pair (public-key systems) P = DKD(EKE(P)) Figure 9-7. Notation used in this chapter. 3/17/2025 Yong Chen, Texas Tech University 19
Cryptography (4) Hash functions: a hash function H takes a message m of arbitrary length as input and produces a bit string h having a fixed length as output: h = H(m) One-way functions: computationally infeasible to find the input m that corresponds to a known output h On the other hand, computing h from m is easy 3/17/2025 Yong Chen, Texas Tech University 20
Cryptography (5) Weak collision resistance Given an input m and its associated output h = H (m), computationally infeasible to find another different input m <>m, such that H (m) = H (m ) Strong collision resistance When given only H, computationally infeasible to find any two different input values m and m'; such that H(m) = H(m') 3/17/2025 Yong Chen, Texas Tech University 21
Secret-Key/Symmetric Cryptography Monoalphabetic substitution: Plaintext: ABCDEFGHIJKLMNOPQRSTUVWXYZ Ciphertext: QWERTYUIOPASDFGHJKLZXCVBNM Other symmetric key algorithms exist and known relatively secure if keys are long enough, e.g. minimally 256-bit keys E.g. DES (Data Encryption Standard) 3/17/2025 Yong Chen, Texas Tech University 22
Symmetric Cryptosystems: DES (1) Data Encryption Standard Operates on 64-bit blocks Outputs encrypted 64-bit block in 16 rounds A different 48-bit key derived from a 56-bit master key Figure 9-8. (a) The principle of DES. 3/17/2025 Yong Chen, Texas Tech University 23
Symmetric Cryptosystems: DES (2) Takes 64-bit block produced in the previous round as input and split into two parts Li = Ri-1 Ri = Li-1 f(Ri-1, Kj) Figure 9-8. (b) Outline of one encryption round. 3/17/2025 Yong Chen, Texas Tech University 24
Symmetric Cryptosystems: DES (3) Figure 9-9. Details of per-round key generation in DES. 3/17/2025 Yong Chen, Texas Tech University 25
Public-Key Cryptography Encryption makes use of an "easy" operation, such as how much is 314159265358979 314159265358979? Decryption without the key requires you to perform a hard operation, such as what is the square root of 3912571506419387090594828508241? 3/17/2025 Yong Chen, Texas Tech University 26
Public-Key Cryptography: How it works Picks a (public key, private key) pair E.g. ssh-keygen Public key is the encryption key, and the private key is the decryption key Message is encrypted with the receiver s public key Only receiver with the private key can decrypt 3/17/2025 Yong Chen, Texas Tech University 27
Public-Key Cryptosystems: RSA (1) RSA, named after its inventors: Rivest, Shamir, and Adleman The security of RSA comes from the fact that no methods are known to efficiently find the prime factors of large numbers It can be shown that each integer can be written as the product of prime numbers For example, 2100 can be written as 2100 = 2 x 2 x 3 x 5 x 5 x 7 In RSA, the private and public keys are constructed from very large prime numbers As it turns out, breaking RSA is equivalent to finding those two prime numbers 3/17/2025 Yong Chen, Texas Tech University 28
Public-Key Cryptosystems: RSA (2) Generating the private and public keys requires four steps: Choose two very large prime numbers, p and q. Compute n = p q and z = (p 1) (q 1). Choose a number d that is relatively prime to z. Compute the number e such that e d = 1 mod z (the smallest integer in the series z+1, 2z+1, 3z+1, ) One of d and e can be used for public key and the other for private key 3/17/2025 Yong Chen, Texas Tech University 29
Public-Key Cryptosystems: RSA (3) RSA considers each message m to be just a string of bits. Each message is first divided into fixed-length blocks, where each block miinterpreted as a binary number To encrypt message m, the sender calculates for each block mi, the value ci= mie(mod n), which is then sent to the receiver Decryption at the receiver s side takes place by computing mi = cid(mod n) Computation intensive, often encrypt keys, instead of normal data 3/17/2025 Yong Chen, Texas Tech University 30
Hash Functions: MD5 MD5 is a hash function for computing a 128-bit, fixed length message digest from an arbitrary length binary input string Figure 9-10. The structure of MD5. 3/17/2025 Yong Chen, Texas Tech University 31