CL - CY Level - 1 Report
29 / 3 / 2025
R Rohan Shalom - Level 1 Report
TASK 1: Socket.IO
In this task, I learned how to build a real-time chat application using Socket.IO, the Node.js framework, and HTML and CSS for the frontend. This provided insight into the functioning of web sockets and how they can be implemented effectively in chat applications.
GitHub Repository: RohChat
Understanding WebSockets
WebSockets enable real-time, full-duplex communication between the client and server over a single persistent connection, unlike traditional HTTP, which follows a request-response model. This capability allows both client and server to send messages anytime.
Key Features of WebSockets:
- Handshake Signals: Establish the connection.
- Persistent Connection: Maintains a continuous connection.
- Message Exchange: Enables bidirectional data transfer.
- Closing the Connection: Ensures proper termination of communication.
Applications:
WebSockets are ideal for chat applications, live updates, collaborative document editing, IoT data streaming, and more.
Advantages:
- Efficiency: Reduces overhead by maintaining a single connection.
- Flexibility: Supports real-time communication.
- Scalability: Handles high traffic effectively.
Challenges:
- Complexity: Requires careful implementation to avoid security vulnerabilities.
TASK 2: Encryption Techniques - Secure Messaging App
Using the pycryptodome library, I developed a secure messaging app that encrypts user input into ciphertext and decrypts it back into plaintext. This task involved understanding cryptographic principles and implementing AES (Advanced Encryption Standard) encryption and decryption algorithms.
GitHub Repository: Crypto
Core Concepts in Cryptography:
- Ciphertext: Encrypted, unreadable data generated from plaintext.
- Tag: Ensures integrity and authenticity of the encrypted message.
- Nonce: Random value ensuring unique encryption results.
- Key: The secret value used for encryption and decryption.
Symmetric Key Cryptography:
- A single key is used for both encryption and decryption.
Asymmetric Key Cryptography:
- Uses a key pair: a public key for encryption and a private key for decryption.
How Prime Numbers are Used in RSA:
- Select Two Large Primes:
p
andq
. - Compute n:
n = p × q
. - Calculate φ(n): Euler's Totient:
φ(n) = (p-1) × (q-1)
. - Choose e: Public key exponent satisfying
1 < e < φ(n)
andgcd(e, φ(n)) = 1
. - Compute d: Private key exponent satisfying
e × d mod φ(n) = 1
. - Keys: Public key
(e, n)
and private key(d, n)
.
TASK 3: IaaS, PaaS, and SaaS
What is Cloud Computing?
Cloud computing involves delivering computing services over the internet rather than storing them locally. These services include storage, databases, networking, software, and analytics.
Cloud services are categorized into three models:
- IaaS: Infrastructure as a Service
- PaaS: Platform as a Service
- SaaS: Software as a Service
1. IaaS (Infrastructure as a Service)
IaaS provides IT infrastructure (e.g., compute, storage, networking) on a pay-as-you-go basis.
Key Features:
- Resources: Virtualized CPUs, GPUs, RAM, and storage.
- Monitoring: Includes performance tracking and security measures.
- Automation: Handles tasks like backups and load balancing.
Benefits:
- Speed: Rapid provisioning of resources.
- Performance: Geographically distributed data centers reduce latency.
- Reliability: Supports backups and disaster recovery.
- Scalability: Easily scales resources as needed.
Use Cases:
- High-performance computing, website hosting, big data analytics, and app development.
2. PaaS (Platform as a Service)
PaaS simplifies application development by providing tools, databases, and frameworks on a managed platform.
Key Features:
- Prebuilt connectors for integrations.
- Supports custom workflows with data transformation capabilities.
Benefits:
- Automation: Reduces manual tasks.
- Scalability: Adapts to large system requirements.
- Ease of Use: User-friendly tools with robust security features.
Use Cases:
- Automating workflows, keeping data synchronized, and connecting disparate systems.
3. SaaS (Software as a Service)
SaaS provides software applications hosted by vendors and accessed via browsers. It eliminates the need for infrastructure or software maintenance.
Key Features:
- Hosted applications accessed via login.
- Operates on a multi-tenant model.
Benefits:
- Accessibility: Available from any internet-enabled device.
- Cost Efficiency: Reduces upfront and maintenance costs.
- Automatic Updates: Ensures the software is up-to-date.
Use Cases:
- Gmail, Google Drive, Salesforce, Zoom, Shopify, QuickBooks, and Netflix.
TASK 4: OSI Model
The OSI (Open Systems Interconnection) model defines how data is transmitted across networks. It comprises seven layers, each responsible for specific communication functions, enabling interoperability between systems.
The Seven Layers:
- Application Layer: Interfaces with the user (e.g., web browsers, apps).
- Presentation Layer: Formats, encrypts, and compresses data (e.g., HTTPS).
- Session Layer: Manages connections between devices.
- Transport Layer: Ensures reliable data transfer (e.g., TCP).
- Network Layer: Routes data using IP addresses.
- Data Link Layer: Handles error correction and data flow within networks.
- Physical Layer: Transmits raw data via hardware (e.g., cables, Wi-Fi).
Analogy: Online Shopping
- Physical Layer: Delivery trucks and roads.
- Data Link Layer: Packaging and labeling.
- Network Layer: Delivery routing.
- Transport Layer: Ensures undamaged delivery.
- Session Layer: Maintains your connection with the website.
- Presentation Layer: Displays order details and encrypts payment data.
- Application Layer: E-commerce platform (e.g., Amazon).