Viva prep · Real questions · Student experiences Enroll in Bootcamp

Proctor workspace

Proctor Level2_98

Share your experience Add your viva experience here
8 Questions
3 Sets
0 Topics
0 Reviews

Student reviews

No student reviews for this proctor yet.

Approved viva sets

Download all
  1. 1
    in network tab of inspect after logging in, in the payload section : password was visible, question was how to hide that ?
    Times asked 2
  2. 2
    how to implement template inheritance functionality (MAD1) in Vue? [question was in context of displaying Navbar on everypage]
    Times asked 2
  1. 1
    what is : on delete cascade ,
    Times asked 1
    Official solution

    SimpleCascade parent ke saath child pe automatic action (generally delete).

    Company delete → uski drives bhi delete, warna orphan rows / FK error.
    SQLAlchemy: db.relationship('Drive', cascade='all, delete-orphan', backref='company')
    SQL: ForeignKey(..., ondelete='CASCADE')

    Cascade sirf delete nahi: save-update, merge, refresh-expire, expunge, delete-orphan.
    Cascade Update: parent PK change to child FK update (rare, PK mat badlo).
    Parent delete jab children active hon: constraint error, ya cascade se children gayab, ya pehle children handle karo — design choice examiner poochta hai.
    CSS cascading alag topic hai (styles inherit/override).

  2. 2
    in network tab of inspect after logging in, in the payload section : password was visible, question was how to hide that ?
    Times asked 2
    Official solution

    SimpleNetwork tab mein password dikhna HTTPS pe encrypted transit hai, DevTools local dikhata hai. Kabhi query string mein password mat bhejo — POST body. Production HTTPS mandatory.

  3. 3
    how to implement template inheritance functionality (MAD1) in Vue? [question was in context of displaying Navbar on everypage]
    Times asked 2
    Official solution

    SimpleBase template pe navbar/footer, child pages {% extends %} + {% block %} se content bharte hain. DRY.

    Example

    {# base.html #}
    {% block content %}{% endblock %}
    
    {# home.html #}
    {% extends 'base.html' %}
    {% block content %}
      <h1>Home</h1>
    {% endblock %}
  1. 1
    What is ON DELETE CASCADE?
    Times asked 3
    Official solution

    SimpleCASCADE = parent gaya to bacche bhi. Restrict = pehle bacche sambhalo.

    ON DELETE CASCADE SQL. SQLAlchemy cascade='all, delete-orphan' collection se orphans.
    Opposite auto nahi — child delete se parent nahi marata.

    Venue delete: bookings restrict (safer viva) ya cascade+cancel policy. Examiner design poochta hai.

    ON UPDATE CASCADE PK change — rare. SET NULL, RESTRICT bhi options.

    Example

    shows = db.relationship('Show', cascade='all, delete-orphan', back_populates='venue')

    Project example: Show belongs Venue delete-orphan. Booking venue pe restrict — 'reassign first'.

    Viva tipVenue delete pe bookings: restrict (mat delete) ya cascade+refund policy. Examiner design poochta hai. Cascade UPDATE bhi hota hai (PK change) — rare.

  2. 2
    In the browser's Network tab, after logging in, the password is visible in the request payload. How would you prevent or hide it?
    Times asked 1
    Official solution

    SimpleHTTPS encrypt transit. Network tab YOUR machine dikhega. Prod HTTPS. Never log passwords. Type=password UI only.

    In Network tab password visible how prevent/hide.

    Authentication poochta hai "tu kaun hai?", Authorization poochta hai "tujhe yeh kaam karne ki permission hai?"

    Authentication: login. Username + password hash check. Success pe JWT/session. Galat credentials = 401.
    Authorization: uske baad role. Admin hi venue/lot delete kare, student nahi = 403 (logged in ho, allowed nahi).

    MAD2: POST /api/login = authentication. @jwt_required identity. @roles_required('admin') ya Vue v-if="isAdmin" = authorization. Frontend hide sirf UX — asli deny backend pe.

    Validation alag: form sahi bhara (email format, age 18+). Woh identity prove nahi karta. Password store hash (Werkzeug), JWT payload padha ja sakta hai isliye secret mat daalo.

    Project example: Can't hide from user's own DevTools. HTTPS + don't echo password response.

  3. 3
    How would you implement template inheritance (MAD1) in Vue? (For example, displaying the Navbar on every page.)
    Times asked 1
    Official solution

    SimpleApp.vue Navbar + router-view. v-if isLoggedIn links.

    MAD1 extends equivalent.

    SPA = ek HTML, Vue Router se views, full reload nahi. MPA = MAD1 Jinja har URL naya HTML.

    Vue Router: routes array, router-view, router-link, meta.auth + beforeEach guard. Dynamic /venues/:id$route.params.id.

    Vite/CLI SFC + npm build dist/. CDN script tag, no SFC. Jo tumne use kiya wahi justify. Flask send_from_directory('dist') production pattern.

    Project example: Navbar.vue.

    Project example: Navbar.vue.

Maintaine By Lazy IITians Team + IITM BS students Regualr for More data you have