Chapterبەش 4 · Lectureوانە 4.4

Securing Routing Updates: RIP Authentication and Passive Interfacesپاراستنی نوێکردنەوەکانی ڕێدۆزی: پشتڕاستکردنەوەی ناسنامەی RIP و نێوبەستە ناچالاکەکان

Why routers must not trust every update; authentication with a shared key (plain text vs MD5); key chains, key numbers and the real meaning of accept-lifetime and send-lifetime; the correct Cisco IOS configuration (key chain in global mode, ip rip authentication on the interface) with verification; passive interfaces and passive-interface default; and why MD5 is legacy today.

بۆچی نابێت متمانە بە هەموو نوێکردنەوەیەک بکەن؛ بە هاوبەش ( بەرامبەر ⁦MD5⁩)؛ ، ژمارەی و واتای ڕاستەقینەی ⁦accept-lifetime⁩ و ⁦send-lifetime⁩؛ دروستی Cisco IOS ( لە باری گشتیدا، ip rip authentication لەسەر ) لەگەڵ پشکنین؛ و ⁦passive-interface default⁩؛ و بۆچی ⁦MD5⁩ ئەمڕۆ کۆنە.

21 min read22 خولەک خوێندنەوە · 20 stepsهەنگاو

What you will learnچی فێر دەبیت

  • Explain how a rogue router can abuse RIP and what authentication adds.
  • Compare plain-text and MD5 authentication and say what MD5 does and does not protect.
  • Configure a key chain and RIP MD5 authentication in the right modes, and verify it.
  • Use accept-lifetime and send-lifetime to change keys without a gap.
  • Configure passive interfaces and explain what they change in RIP, OSPF and EIGRP.
  • ڕوون بکەیتەوە نەناسراو چۆن دەتوانێت خراپ سوود لە وەربگرێت و چی زیاد دەکات.
  • و ⁦MD5⁩ بەراورد بکەیت و بڵێیت ⁦MD5⁩ چی دەپارێزێت و چی ناپارێزێت.
  • و ⁦MD5⁩ـی لە بارە دروستەکاندا ڕێک بخەیت و بیپشکنیت.
  • ⁦accept-lifetime⁩ و ⁦send-lifetime⁩ بۆ گۆڕینی بێ پچڕان بەکار بهێنیت.
  • ڕێک بخەیت و ڕوون بکەیتەوە لە ، و چی دەگۆڕن.

Why routing updates need protectionبۆچی نوێکردنەوەکانی ڕێدۆزی پاراستنیان پێویستە

In RIP every router tells its neighbours which networks it can reach, and the neighbours simply believe what they hear. That trust is a weak point. Someone can plug a laptop running routing software into the link between two routers — a rogue router — and send fake updates. The real routers put the fake routes into their routing tables, and traffic goes where the attacker wants: into a black hole, or through the attacker’s laptop, where it can be read. A wrongly configured router can do the same damage by accident.

لە (وانەی RIP) هەر بە دراوسێکانی دەڵێت دەتوانێت بگاتە کام و دراوسێکانیش ئەوەی دەیبیستن ڕاستەوخۆ باوەڕی پێ دەکەن. ئەم متمانەیە . کەسێک دەتوانێت لاپتۆپێک کە لەسەرە بە بەستەری نێوان دوو ببەستێت — نەناسراو — و نوێکردنەوەی ساختە بنێرێت. ڕێگە ساختەکان دەخەنە ناو و هاتوچۆ دەچێتە ئەو شوێنەی دەیەوێت: بۆ ناو کونێکی ڕەش، یان بە لاپتۆپەکەی کە لەوێ دەخوێنرێتەوە. هەڵە ڕێکخراو بە هەڵە دەتوانێت هەمان زیان بگەیەنێت.

The more routers a network has, the bigger the danger. RIP authentication closes the door: the routers share a secret key, and every update must prove that its sender knows the key. Only an authenticated router can send routing information that the others accept. RIP version 2 supports authentication; RIP version 1 does not.

تا زیاتری هەبێت، مەترسییەکە گەورەترە. ئەم دەرگایە دادەخات: نهێنی بەش دەکەن و هەموو نوێکردنەوەیەک دەبێت بیسەلمێنێت کە نێرەرەکەی ئەو دەزانێت. تەنیا سەلمێنراو دەتوانێت زانیاریی بنێرێت کە ئەوانی تر وەریبگرن. وەشانی 2ی پشتگیریی دەکات؛ وەشانی 1 ناکات.

Animation in six steps. 1: R2 advertises 192.168.2.0/24 to R1 through switch SW0. 2: a rogue laptop on SW0 sends a fake update with 192.168.2.0/25 and 192.168.2.128/25. 3: R1 puts both fake routes in its table, because a longer prefix wins. 4: PC1's packets for PC2 go to the rogue. 5: with a shared key, R2's update carries a valid MD5 digest and is accepted. 6: the rogue has no key; R1 prints 'RIP: ignored v2 packet from 192.168.12.66 (invalid authentication)' and traffic stays safe.
Animation in six steps. 1: R2 advertises 192.168.2.0/24 to R1 through switch SW0. 2: a rogue laptop on SW0 sends a fake update with 192.168.2.0/25 and 192.168.2.128/25. 3: R1 puts both fake routes in its table, because a longer prefix wins. 4: PC1's packets for PC2 go to the rogue. 5: with a shared key, R2's update carries a valid MD5 digest and is accepted. 6: the rogue has no key; R1 prints 'RIP: ignored v2 packet from 192.168.12.66 (invalid authentication)' and traffic stays safe.
Without authentication any device on the link can steer traffic; with it, only routers that know the key are believed.بێ هەر ئامێرێک لەسەر بەستەرەکە دەتوانێت هاتوچۆ ئاڕاستە بکات؛ بە ، تەنیا ئەو دەزانن باوەڕیان پێ دەکرێت.CêIT

A reminder: what the updates carryبیرخستنەوە: نوێکردنەوەکان چی هەڵدەگرن

Routing information is what a router needs to forward packets. Every packet carries a source and a destination address in its header; the router reads the destination, looks it up in its routing table and sends the packet to the next hop (how routers forward). A routing protocol fills that table. RIP sends its whole table to its neighbours every 30 seconds (how RIP works), so a fake entry would come back again and again.

زانیاریی ئەوەیە کە بۆ پێویستیەتی. هەموو ناونیشانی سەرچاوە و مەبەست لە سەرەکەیدا هەڵدەگرێت؛ ناونیشانی مەبەست دەخوێنێتەوە، لە بەدوایدا دەگەڕێت و دەنێرێت بۆ (ڕێدۆز چۆن پاکێت دەنێرێت). ئەو خشتەیە پڕ دەکاتەوە. هەموو ⁦30⁩ چرکە جارێک هەموو خشتەکەی بۆ دراوسێکانی دەنێرێت (RIP چۆن کار دەکات)، بۆیە دێڕێکی ساختە جار لەدوای جار دەگەڕایەوە.

R2 sends R1 a RIPv2 update every 30 seconds to 224.0.0.9 on UDP port 520. It carries the line 192.168.2.0/24 metric 1. R1 adds R 192.168.2.0/24 [120/1] to its routing table.R2 هەموو 30 چرکە جارێک نوێکردنەوەیەکی RIPv2 بۆ 224.0.0.9 لەسەر پۆرتی UDP 520 دەنێرێت بۆ R1. دێڕی 192.168.2.0/24 metric 1 هەڵدەگرێت. R1 دێڕی R 192.168.2.0/24 [120/1] دەخاتە خشتەی ڕێدۆزییەکەیەوە.
One update line becomes one routing-table line.یەک دێڕی نوێکردنەوە دەبێتە یەک دێڕی .CêIT

What authentication meansپشتڕاستکردنەوەی ناسنامە واتای چییە

The English word comes from authentic: genuine, proven to be what it claims. English-speaking Muslims say authentic hadith for a saying whose chain of narrators has been checked and proven trustworthy. In IT, authentication is checking the identity of a user or a system before trusting it: with a username and password, a fingerprint, or a code on a smart card. It is like the amusement park in Chavi Land, where customers join a ride by showing their card at the gate.

وشە ئینگلیزییەکە لە authenticـەوە هاتووە: ڕەسەن، سەلمێنراو کە ئەوەیە کە دەڵێت. موسڵمانانی ئینگلیزیزمان بۆ فەرموودەیەک کە زنجیرەی گێڕەرەوەکانی پشکنراوە و متمانەپێکراویی سەلمێنراوە دەڵێن authentic hadith (فەرموودەی سەحیح). لە ، پشکنینی ناسنامەی بەکارهێنەرێک یان سیستەمێکە پێش متمانەکردن پێی: بە و ، جێ‌پەنجە، یان کۆدێک لەسەر کارتێکی زیرەک. وەک شاری یاریی چاڤیلاند وایە، کە کڕیاران بە پیشاندانی کارتەکەیان لە دەرگاکەدا بەشداری یارییەک دەکەن.

Definitionپێناسە

Checking who a user is, usually with a username and password. If the details are correct, the user is logged in. It answers 'Who are you?'; answers 'What may you do?'.

پشکنینی ئەوەی بەکارهێنەرێک کێیە، زۆرجار بە ناوی بەکارهێنەر و تێپەڕەوشە. ئەگەر زانیارییەکان دروست بن، بەکارهێنەرەکە دەچێتە ژوورەوە. وەڵامی «تۆ کێیت؟» دەداتەوە؛ وەڵامی «بۆت هەیە چی بکەیت؟» دەداتەوە.

Three ways to prove who you are: a password, a fingerprint and a smart card. Beside them, a ride gate with a card reader: card accepted, the gate opens; no card, no ride. A router does the same with updates that lack the right key.سێ ڕێگە بۆ سەلماندنی ئەوەی کێیت: تێپەڕەوشە، جێ‌پەنجە و کارتی زیرەک. لە تەنیشتیان دەرگایەکی یاری بە کارت‌خوێنەرەوە: کارت قبووڵ کرا، دەرگا دەکرێتەوە؛ بێ کارت، یاری نییە. ڕێدۆز هەمان کار لەگەڵ ئەو نوێکردنەوانە دەکات کە کلیلی دروستیان نییە.
A router checks every update the way the gate checks every card. هەموو نوێکردنەوەیەک دەپشکنێت وەک چۆن دەرگاکە هەموو کارتێک دەپشکنێت.CêIT

People and services have their own lesson about passwords and multi-factor authentication (proving who you are). Here the ones who prove themselves are routers, and their “card” is a shared secret key.

خەڵک و خزمەتگوزارییەکان وانەی تایبەتی خۆیان هەیە لەبارەی و (سەلماندنی ئەوەی کێیت). لێرەدا ئەوانەی خۆیان دەسەلمێنن و «کارتەکەیان» نهێنیی هاوبەشە.

How RIP authentication works: plain text or MD5پشتڕاستکردنەوەی ناسنامەی RIP چۆن کار دەکات: دەقی ئاشکرا یان ⁦MD5⁩

Both neighbours are given the same secret key. When a router receives an update, it checks the authentication data first; if it is wrong or missing, the router ignores the whole update. Cisco IOS offers two modes for RIPv2:

هەردوو دراوسێ هەمان نهێنییان پێ دەدرێت. کاتێک نوێکردنەوەیەک وەردەگرێت، سەرەتا زانیاریی دەپشکنێت؛ ئەگەر هەڵە یان بزر بێت، هەموو نوێکردنەوەکە پشتگوێ دەخات. Cisco IOS بۆ ⁦RIPv2⁩ دوو شێواز پێشکەش دەکات:

  • Plain text (the default when authentication is on): the key itself travels inside every update. Anyone who captures one update reads the key, so Cisco says not to use it where security matters.
  • MD5: the router computes a digest of the update together with the key and sends only the digest. The key never leaves the router; the receiver computes the digest again with its own copy of the key and compares.
  • (بنەڕەت کاتێک هەڵکراوە): خودی لە ناو هەموو نوێکردنەوەیەکدا دەگوازرێتەوە. هەر کەسێک یەک نوێکردنەوە بگرێت دەخوێنێتەوە، بۆیە Cisco دەڵێت لەو شوێنانەی ئاسایش گرنگە بەکاری مەهێنە.
  • ⁦MD5⁩: لە نوێکردنەوەکە لەگەڵ پێکەوە دەژمێرێت و تەنیا دەنێرێت. هەرگیز لە دەرناچێت؛ وەرگرەکە بە کۆپیی خۆی دووپاتە دەژمێرێت و بەراوردی دەکات.
Left, plain text: the update carries 'routes' and 'key: Rip-Key-2026', and an eye shows that anyone who captures it reads the key. Right, MD5: the update carries 'routes' and a digest; the digest is MD5(update + key); the key never leaves the router and the receiver computes the digest again. Neither mode encrypts the routes.لای چەپ، دەقی ئاشکرا: نوێکردنەوەکە «ڕێگەکان» و «key: Rip-Key-2026» هەڵدەگرێت و چاوێک پیشان دەدات هەر کەسێک بیگرێت کلیلەکە دەخوێنێتەوە. لای ڕاست، MD5: نوێکردنەوەکە «ڕێگەکان» و نرخێکی هاش هەڵدەگرێت؛ نرخی هاشەکە MD5(update + key)ـە؛ کلیلەکە لە ڕێدۆز دەرناچێت و وەرگرەکە دووپاتە دەیژمێرێت. هیچیان شفرەکردنی ڕێگەکان ناکەن.
Plain text shows the key to everyone; MD5 shows only a digest. بە هەمووان پیشان دەدات؛ ⁦MD5⁩ تەنیا .CêIT

What MD5 is — and why it is old⁦MD5⁩ چییە — و بۆچی کۆنە

MD5 stands for Message Digest 5; the 5 is its version. It is a hash function: it takes any input — one word or a whole file — and produces a fixed 128-bit hash value, written as 32 hexadecimal digits. The output is much smaller than the input, which is why it is called a digest: like food in the stomach, the message is broken down into something small. Change one character of the input and the digest changes completely. The Cybersecurity lesson on hashing explains hash functions in full.

⁦MD5⁩ کورتکراوەی Message Digest 5ـە؛ 5 وەشانەکەیەتی. : هەر وەردەگرێت — یەک وشە یان فایلێکی تەواو — و جێگیری ⁦128⁩ بەرهەم دەهێنێت کە بە ⁦32⁩ ژمارەی دەنووسرێت. زۆر بچووکترە لە ، بۆیە پێی دەگوترێت digest (هەرسکراو): وەک خواردن لە ناو گەدەدا، پەیامەکە دەکرێتە شتێکی بچووک. یەک لە بگۆڕە و بە تەواوی دەگۆڕێت. وانەی کرداری هاش لە ئاسایشی سایبەریدا بە تەواوی ڕوونی دەکاتەوە.

Password123 goes through MD5 and becomes 42f749ade7f9e195bf475f37a44cafcb; Password124 becomes 0da21eca396b1532f6cccf167234b441. One changed character gives a completely different 32-digit digest. A warning says MD5 is broken for collisions.Password123 بە MD5دا تێدەپەڕێت و دەبێتە 42f749ade7f9e195bf475f37a44cafcb؛ Password124 دەبێتە 0da21eca396b1532f6cccf167234b441. یەک نووسەی گۆڕاو نرخێکی هاشی 32 ژمارەیی بە تەواوی جیاواز دەدات. ئاگادارییەک دەڵێت MD5 بۆ پێکدادانی هاش شکاوە.
Real MD5 digests, computed with Python's hashlib. ڕاستەقینەی ⁦MD5⁩، بە hashlibـی ژمێردراون.CêIT

In RIP, MD5 is used to protect the authenticity and integrity of updates — that they come from a router that knows the key and were not changed on the way — against attackers and untrusted outsiders. It is not encryption: the routes are still readable. And MD5 is no longer strong: since 2004 researchers can make two different inputs with the same MD5 digest (a collision; see How MD5 and SHA-1 grew old), and RFC 6151 (2011) says not to use it where that matters. Keyed MD5 in RIP is a legacy method, still taught because Cisco IOS and Packet Tracer offer it; the last screens show the modern choices.

لە ، ⁦MD5⁩ بۆ پاراستنی و نوێکردنەوەکان بەکار دێت — کە لە هاتوون کە دەزانێت و لە ڕێگادا نەگۆڕدراون — لە بەرامبەر و دەرەکییە متمانەپێنەکراوەکان. نییە: ڕێگەکان هێشتا دەخوێنرێنەوە. ⁦MD5⁩ ئیتر بەهێز نییە: لە ⁦2004⁩ـەوە توێژەران دەتوانن دوو جیاواز بە هەمان ⁦MD5⁩ دروست بکەن (؛ بڕوانە ⁦MD5⁩ و ⁦SHA-1⁩ چۆن کۆن بوون). هەروەها ⁦RFC 6151 (2011)⁩ دەڵێت لەو شوێنانەی ئەمە گرنگە بەکاری مەهێنن. ⁦MD5⁩ـی بە لە ڕێگایەکی کۆنە، هێشتا فێر دەکرێت چونکە Cisco IOS و Packet Tracer پێشکەشی دەکەن؛ دواین شاشەکان هەڵبژاردە نوێیەکان پیشان دەدەن.

Key chains: where the keys liveزنجیرەکلیلەکان: کلیلەکان لە کوێ دادەنرێن

Cisco IOS keeps routing keys in a key chain: a named holder of keys, like a ring of real keys. Each key in the chain has its own number, its own secret key-string and its own lifetimes. Key numbers go from 0 to 2147483647 and do not have to follow each other. When a router sends an update, it starts with the lowest key number and uses the first key that is valid at that moment.

Cisco IOS لە هەڵدەگرێت: هەڵگرێکی ناودار بۆ ، وەک ئەڵقەیەک کلیلی ڕاستەقینە. هەر لە زنجیرەکەدا ژمارەی تایبەتی خۆی، ⁦key-string⁩ـی نهێنیی خۆی و ماوەکانی کارکردنی خۆی هەیە. ژمارەی لە 0ـەوە تا ⁦2147483647⁩ـە و پێویست ناکات بەدوای یەکدا بێن. کاتێک نوێکردنەوەیەک دەنێرێت، لە کەمترین ژمارەی دەست پێ دەکات و یەکەم بەکار دەهێنێت کە لەو کاتەدا دروستە.

Definitionپێناسە

A named set of numbered keys on a router (key chain RIPKEYS, key 1, key-string …), each with optional send and accept lifetimes, used to authenticate the routing updates that neighbours send.

کۆمەڵێکی ناودار لە ژمارەدارە لەسەر (key chain RIPKEYS، key 1، key-string …)، هەریەکەیان دەکرێت ماوەی ناردن و وەرگرتنی هەبێت؛ بۆ ئەو نوێکردنەوانەی ڕێدۆزی بەکار دێت کە دەینێرن.

A ring labelled key chain RIPKEYS holds two keys. Key 1: key-string Rip-Key-2026, send from 1 Jan 2026 to 1 Jul 2026. Key 2: key-string Rip-Key-2026b, send from 1 Jul 2026 with no end. Each key number can be 0–2147483647.ئەڵقەیەک بە ناوی زنجیرەکلیلە RIPKEYS دوو کلیل هەڵدەگرێت. کلیل 1: key-string Rip-Key-2026، ناردن لە 1ی کانوونی دووەمی 2026 تا 1ی تەممووزی 2026. کلیل 2: key-string Rip-Key-2026b، ناردن لە 1ی تەممووزی 2026ـەوە بێ کۆتایی. ژمارەی هەر کلیلێک دەتوانێت 0–2147483647 بێت.
One chain, several keys: each with a number, a secret and a time to work.یەک زنجیرە، چەند : هەریەکە بە ژمارەیەک، نهێنییەک و کاتێکی کارکردن.CêIT
The caretaker's key ringئەڵقە کلیلی پاسەوانی قوتابخانە

A school caretaker carries one ring with many numbered keys. When the lock of room 7 is changed next month, a new key is added before the old one is thrown away, so no door is ever locked out. A key chain lets a router change its secret the same way.

پاسەوانی قوتابخانەیەک یەک ئەڵقە هەڵدەگرێت بە چەندین کلیلی ژمارەدارەوە. کاتێک قفڵی ژووری 7 مانگی داهاتوو دەگۆڕدرێت، کلیلێکی نوێ پێش فڕێدانی کلیلە کۆنەکە زیاد دەکرێت، بۆیە هیچ دەرگایەک بێ کلیل نامێنێتەوە. ڕێگە بە دەدات بە هەمان شێوە نهێنییەکەی بگۆڕێت.

Where the analogy stops workingسنووری ئەم نموونەیە

A real key opens a lock by its shape; a routing key is never shown to the other side — in MD5 mode only a digest made with it travels.

کلیلی ڕاستەقینە بە شێوەکەی قفڵ دەکاتەوە؛ هەرگیز بە لایەنەکەی تر پیشان نادرێت — لە شێوازی ⁦MD5⁩ـدا تەنیا کە پێی دروست کراوە دەگوازرێتەوە.

accept-lifetime and send-lifetime: a time window for each key⁦accept-lifetime⁩ و ⁦send-lifetime⁩: ماوەیەکی کات بۆ هەر کلیلێک

Each key can have two time windows. send-lifetime says when the router may use the key to sign the updates it sends. accept-lifetime says when the router accepts updates signed with that key. Outside its windows the key is not valid. The default for both is infinite: valid from now on. Their job is changing keys without a gap: the new key starts to be accepted a little before it is used, and the old key is accepted a little after it stops being used, so routers whose clocks differ slightly keep trusting each other. The routers' clocks must be right — in real networks they are set with NTP.

هەر دەتوانێت دوو ماوەی کاتی هەبێت. ⁦send-lifetime⁩ دەڵێت کەی دەتوانێت بۆ واژووکردنی ئەو نوێکردنەوانەی دەینێرێت بەکار بهێنێت. ⁦accept-lifetime⁩ دەڵێت کەی ئەو نوێکردنەوانە وەردەگرێت کە بەو واژوو کراون. لە دەرەوەی ماوەکانی، دروست نییە. بنەڕەتی هەردووکیان infiniteـە: لە ئێستاوە بۆ هەمیشە دروستە. کاریان گۆڕینی بێ پچڕانە: نوێیەکە کەمێک پێش بەکارهێنانی وەردەگیرێت و کۆنەکە کەمێک دوای وەستانی بەکارهێنانی هێشتا وەردەگیرێت، بۆیە ئەو کاتژمێرەکانیان کەمێک جیاوازە هەر متمانە بە یەکتر دەکەن. دەبێت کاتژمێری ڕاست بێت — لە بە NTP ڕێک دەخرێن.

A timeline from 1 January to after 3 July 2026 (not to scale). Key 1: send-lifetime until 1 July, accept-lifetime a little longer, until 3 July. Key 2: accept-lifetime from 25 June, send-lifetime from 1 July, both with no end. The overlap from 25 June to 3 July is marked: both keys are accepted there. Caption: lifetimes never limit routes and do not stop routing loops.هێڵێکی کات لە 1ی کانوونی دووەم تا دوای 3ی تەممووزی 2026 (بێ پێوەر). کلیل 1: send-lifetime تا 1ی تەممووز، accept-lifetime کەمێک درێژتر، تا 3ی تەممووز. کلیل 2: accept-lifetime لە 25ی حوزەیرانەوە، send-lifetime لە 1ی تەممووزەوە، هەردووکیان بێ کۆتایی. ماوەی هاوبەش لە 25ی حوزەیران تا 3ی تەممووز دیاری کراوە: لەوێدا هەردوو کلیل وەردەگیرێن. ژێرنووس: ماوەکان هەرگیز ماوەی ڕێگەکان دیاری ناکەن و ڕێگری لە ئەڵقەی ڕێدۆزی ناکەن.
Overlapping windows let two routers move from key 1 to key 2 without losing a single update.ماوە هاوبەشەکان ڕێگە بە دوو دەدەن لە 1ـەوە بچنە سەر 2 بێ ئەوەی تەنانەت یەک نوێکردنەوەش لەدەست بدەن.CêIT
Planned key change on R1 (the same on R2)گۆڕینی پلاندانراوی کلیل لەسەر ⁦R1⁩ (هەمان شت لەسەر ⁦R2⁩)TEXT
R1(config)#key chain RIPKEYS
R1(config-keychain)#key 1
R1(config-keychain-key)#key-string Rip-Key-2026
R1(config-keychain-key)#accept-lifetime 00:00:00 Jan 1 2026 00:00:00 Jul 3 2026
R1(config-keychain-key)#send-lifetime 00:00:00 Jan 1 2026 00:00:00 Jul 1 2026
R1(config-keychain-key)#exit
R1(config-keychain)#key 2
R1(config-keychain-key)#key-string Rip-Key-2026b
R1(config-keychain-key)#accept-lifetime 00:00:00 Jun 25 2026 infinite
R1(config-keychain-key)#send-lifetime 00:00:00 Jul 1 2026 infinite
R1(config-keychain-key)#end
R1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 4-5

Start time, then an end time — or infinite, or duration and a number of seconds. Times are hh:mm:ss Month day year.

کاتی دەستپێک، پاشان کاتی کۆتایی — یان infinite، یان duration و ژمارەیەک چرکە. کاتەکان بە شێوەی ⁦hh:mm:ss Month day year⁩ـن.

Lineدێڕی 9-10

Key 2 is accepted from 25 June but used for sending only from 1 July.

2 لە ⁦25⁩ی حوزەیرانەوە وەردەگیرێت بەڵام تەنیا لە 1ی تەممووزەوە بۆ ناردن بەکار دێت.

If the last valid key expires, IOS does not switch authentication off: it keeps using that key and logs an error — so plan the next key in time. Lifetimes say nothing about routes: a route stays in the table as long as RIP's own timers allow. They do not prevent routing loops either; RIP fights loops with a maximum of 15 hops, split horizon, route poisoning and hold-down timers (stopping loops).

ئەگەر دوایین دروست بەسەر بچێت، IOS ناکوژێنێتەوە: بەردەوام ئەو بەکار دەهێنێت و هەڵەیەک تۆمار دەکات — بۆیە داهاتوو لە کاتی خۆیدا پلان بکە. ماوەکان هیچ لەبارەی ڕێگەکان نالێن: ڕێگەیەک تا ئەو کاتە لە خشتەکەدا دەمێنێتەوە کە کاتژمێرەکانی خودی ڕێگە دەدەن. هەروەها ڕێگری لە ناکەن؛ بە زۆرترین ⁦15⁩ ، ، و لە دژی ئەڵقەکان دەجەنگێت (ڕاگرتنی ئەڵقەکانی ڕێدۆزی).

The lab: two RIPv2 routersتاقیگە: دوو ڕێدۆزی ⁦RIPv2⁩

We protect a RIP network like lab 1 of the previous lesson, with one change: R1 and R2 now meet on an Ethernet segment through switch SW0 — the kind of shared link where a stranger can plug in a laptop. They are joined on 192.168.12.0/24 (G0/1 on both), and each router has a LAN with one PC: 192.168.1.0/24 behind R1 and 192.168.2.0/24 behind R2. RIP version 2 already runs on both routers with no auto-summary, and each PC already reaches the other (configuring RIP). Two jobs are left: authenticate the updates on the link between the routers, and make the PC-facing interfaces passive.

وەک تاقیکردنەوەی 1ـی وانەی پێشوو دەپارێزین، بە یەک جیاوازی: ⁦R1⁩ و ⁦R2⁩ ئێستا لەسەر Ethernet بە ⁦SW0⁩ بەیەک دەگەن — ئەو جۆرە بەستەرە هاوبەشەی کەسێکی نەناسراو دەتوانێت لاپتۆپێکی پێوە ببەستێت. لە ڕێی ⁦SW0⁩ـەوە لەسەر ⁦192.168.12.0/24⁩ بەستراون (⁦G0/1⁩ لەسەر هەردووکیان) و هەر بە یەک PCـەوە هەیە: ⁦192.168.1.0/24⁩ لە پشت ⁦R1⁩ و ⁦192.168.2.0/24⁩ لە پشت ⁦R2⁩. وەشانی 2ی پێشتر بە no auto-summary لەسەر هەردوو کار دەکات و هەر PCـێک پێشتر دەگاتە ئەوی تر (ڕێکخستنی RIP). دوو کار ماوە: بۆ نوێکردنەوەکانی سەر بەستەری نێوان دابنێ و ئەو ڕووەو PCـەکانن بکە بە .

PC1 (192.168.1.10) — R1 G0/0 192.168.1.1/24; R1 G0/1 .1 — SW0 — .2 G0/1 R2 on 192.168.12.0/24; R2 G0/0 192.168.2.1/24 — PC2 (192.168.2.10). A note: G0/1 gets authenticated updates, G0/0 becomes passive (only PCs).PC1 (192.168.1.10) — R1 G0/0 192.168.1.1/24؛ R1 G0/1 .1 — SW0 — .2 G0/1 R2 لەسەر 192.168.12.0/24؛ R2 G0/0 192.168.2.1/24 — PC2 (192.168.2.10). تێبینییەک: G0/1 نوێکردنەوەی سەلمێنراو وەردەگرێت، G0/0 دەبێتە نێوبەستەی ناچالاک (تەنیا PC).
The lab: authentication on the router link, passive interfaces towards the PCs.تاقیگەکە: لەسەر بەستەری ، ڕووەو PCـەکان.CêIT

Step 1: create the key chain (global configuration)هەنگاوی 1: زنجیرەکلیلەکە دروست بکە (باری ڕێکخستنی گشتی)

The key chain is a global command; it opens key-chain mode, and key 1 opens key mode inside it. The commands for authentication live in three different places, and none of them is under router rip:

گشتییە؛ باری ⁦key-chain⁩ دەکاتەوە و key 1 باری key لە ناویدا دەکاتەوە. لە سێ شوێنی جیاوازدان و هیچیان لە ژێر router rip نین:

From R1(config)# three branches. 1, key chain RIPKEYS: (config-keychain)# key 1, then (config-keychain-key)# key-string, accept-lifetime, send-lifetime. 2, interface g0/1: (config-if)# ip rip authentication mode md5 and ip rip authentication key-chain RIPKEYS. 3, router rip: (config-router)# version 2, network, passive-interface g0/0, no auto-summary. Warning: keys in a key chain, authentication on the interface — never under router rip.لە R1(config)#ـەوە سێ لق. 1، key chain RIPKEYS: (config-keychain)# key 1، پاشان (config-keychain-key)# key-string، accept-lifetime، send-lifetime. 2، interface g0/1: (config-if)# ip rip authentication mode md5 و ip rip authentication key-chain RIPKEYS. 3، router rip: (config-router)# version 2، network، passive-interface g0/0، no auto-summary. ئاگاداری: کلیلەکان لە زنجیرەکلیلەدا، پشتڕاستکردنەوەی ناسنامە لەسەر نێوبەستە — هەرگیز لە ژێر router rip.
Three modes, three jobs.سێ بار، سێ کار.CêIT
R1: key chain RIPKEYS with key 1⁦R1⁩: زنجیرەکلیلەی RIPKEYS بە کلیل 1ـەوەTEXT
R1>enable
R1#configure terminal
R1(config)#key chain RIPKEYS
R1(config-keychain)#key 1
R1(config-keychain-key)#key-string Rip-Key-2026
R1(config-keychain-key)#exit
R1(config-keychain)#exit
R1(config)#
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 3

The name is local to this router; R2 could call its chain something else.

ناوەکە تەنیا هی ئەم ؛ ⁦R2⁩ دەتوانێت ناوێکی تر لە زنجیرەکەی بنێت.

Lineدێڕی 5

The secret itself — the same string on R2. No lifetimes: the key is valid from now on.

خودی نهێنییەکە — هەمان دەق لەسەر ⁦R2⁩. بێ ماوە: لە ئێستاوە دروستە.

The lab’s key-string is short so it is easy to type. On a real network make it long and random. MD5 is one-way: nobody can turn a digest back into the key. But an attacker who records one update can test guessed keys offline, as fast as their computer allows, until one gives the same digest — a short word such as cisco falls quickly (why length wins).

⁦key-string⁩ـی ئەم تاقیکردنەوەیە کورتە تا بە ئاسانی بنووسرێت. لە ڕاستەقینەدا درێژ و هەڕەمەکیی بکە. ⁦MD5⁩ یەک ئاڕاستەیە: کەس ناتوانێت بگەڕێنێتەوە بۆ . بەڵام کە یەک نوێکردنەوە تۆمار بکات، دەتوانێت لەسەر خۆی و بە هەموو خێرایی ئامێرەکەی گریمانەکراو تاقی بکاتەوە، تا یەکێکیان هەمان بدات — وشەیەکی کورتی وەک cisco زوو دەدۆزرێتەوە (بۆچی درێژی دەباتەوە).

Step 2: switch authentication on, on the interfaceهەنگاوی 2: پشتڕاستکردنەوەی ناسنامە لەسەر نێوبەستەکە هەڵبکە

Authentication is switched on per interface, on the interface that faces the neighbour router. Two commands: the mode (md5; without it the mode is plain text) and the key chain to use. Then save. Do the same on R2's G0/1 with the same key number and key-string. Between the moment you finish R1 and the moment you finish R2, the two routers ignore each other's updates, so in a real network do this in a quiet maintenance time.

بۆ هەر جیا هەڵدەکرێت، لەسەر ئەو ڕووەو . دوو : شێوازەکە (md5؛ بەبێ ئەو شێوازەکە ) و ئەو بەکار دێت. پاشان پاشەکەوتی بکە. هەمان شت لەسەر ⁦G0/1⁩ـی ⁦R2⁩ بکە بە هەمان ژمارەی و ⁦key-string⁩. لە نێوان تەواوکردنی ⁦R1⁩ و تەواوکردنی ⁦R2⁩دا، دوو نوێکردنەوەکانی یەکتر پشتگوێ دەخەن، بۆیە لە ڕاستەقینەدا لە کاتێکی ئارامی چاککردنەوەدا بیکە.

R1: authenticate RIP on G0/1⁦R1⁩: پشتڕاستکردنەوەی ناسنامە بۆ RIP لەسەر ⁦G0/1⁩TEXT
R1(config)#interface g0/1
R1(config-if)#ip rip authentication mode md5
R1(config-if)#ip rip authentication key-chain RIPKEYS
R1(config-if)#end
R1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 2

MD5 digest instead of the default plain text.

⁦MD5⁩ لە جیاتی بنەڕەت.

Lineدێڕی 3

Without a key chain on the interface, no authentication is done at all.

بەبێ لەسەر ، هیچ ناکرێت.

R1 with two interfaces. G0/0 towards the LAN: no key. G0/1 towards R2, with a padlock: mode md5, key-chain RIPKEYS. Only updates on G0/1 are signed and checked; the same commands go on R2 G0/1.R1 بە دوو نێوبەستەوە. G0/0 ڕووەو ڕایەڵەی ناوچەیی: بێ کلیل. G0/1 ڕووەو R2، بە قفڵێکەوە: mode md5، key-chain RIPKEYS. تەنیا نوێکردنەوەکانی سەر G0/1 واژوو و پشکنین دەکرێن؛ هەمان فەرمانەکان لەسەر R2 G0/1 دەنووسرێن.
Each interface decides for itself whether it signs and checks updates.هەر خۆی بڕیار دەدات کە نوێکردنەوەکان واژوو و پشکنین بکات یان نا.CêIT

What must match on both neighboursچی دەبێت لەسەر هەردوو دراوسێ وەک یەک بێت

Authentication works only when both sides agree. In MD5 mode the key number, the key-string and the mode must be the same on R1 and R2, and the key must be valid now on both (lifetimes and clocks). The key chain name is only a local label: R1 may call it RIPKEYS and R2 R2-KEYS. If anything that must match does not, each router ignores the other's updates and the RIP routes disappear after a few minutes.

تەنیا کاتێک کار دەکات کە هەردوو لا ڕێک بکەون. لە شێوازی ⁦MD5⁩ـدا ژمارەی ، ⁦key-string⁩ و شێوازەکە دەبێت لەسەر ⁦R1⁩ و ⁦R2⁩ وەک یەک بن و دەبێت ئێستا لەسەر هەردووکیان دروست بێت (ماوەکان و کاتژمێرەکان). ناوی تەنیا نیشانەیەکی ناوخۆییە: ⁦R1⁩ دەتوانێت ناوی بنێت RIPKEYS و ⁦R2⁩ ناوی بنێت ⁦R2-KEYS⁩. ئەگەر هەر شتێک کە دەبێت وەک یەک بێت جیاواز بێت، هەر نوێکردنەوەکانی ئەوی تر پشتگوێ دەخات و ڕێگەکانی دوای چەند خولەکێک نامێنن.

A comparison of R1 and R2. Key chain name: RIPKEYS and R2-KEYS — may differ. Key number: 1 and 1 — must match. Key-string: Rip-Key-2026 on both — must match. Mode: md5 on both — must match. Lifetime: valid now on both — must match.بەراوردی R1 و R2. ناوی زنجیرەکلیلە: RIPKEYS و R2-KEYS — دەکرێت جیاواز بێت. ژمارەی کلیل: 1 و 1 — دەبێت وەک یەک بێت. key-string: Rip-Key-2026 لەسەر هەردووکیان — دەبێت وەک یەک بێت. شێواز: md5 لەسەر هەردووکیان — دەبێت وەک یەک بێت. ماوە: ئێستا دروستە لەسەر هەردووکیان — دەبێت وەک یەک بێت.
Four things must match; the chain name need not.چوار شت دەبێت وەک یەک بن؛ ناوی زنجیرەکە پێویست ناکات.CêIT

Verify: show ip protocols and debug ip ripپشکنین: show ip protocols و debug ip rip

show ip protocols lists every RIP interface with the key chain it uses. debug ip rip shows each update as it arrives — a good update first says it was received with MD5 authentication. Turn debugging off with undebug all when you have seen enough.

show ip protocols هەموو لەگەڵ ئەو بەکاری دەهێنێت ڕیز دەکات. debug ip rip هەر نوێکردنەوەیەک لە کاتی گەیشتنیدا پیشان دەدات — نوێکردنەوەیەکی دروست سەرەتا دەڵێت بە ⁦MD5⁩ وەرگیراوە. کاتێک بەسەت بینی، بە undebug all debug بکوژێنەرەوە.

show ip protocols (selected lines)show ip protocols (چەند دێڕێکی هەڵبژێردراو)TEXT
R1#show ip protocols
Routing Protocol is "rip"
  Sending updates every 30 seconds, next due in 12 seconds
  Default version control: send version 2, receive version 2
    Interface             Send  Recv  Triggered RIP  Key-chain
    GigabitEthernet0/0    2     2
    GigabitEthernet0/1    2     2                    RIPKEYS
  Routing Information Sources:
    Gateway         Distance      Last Update
    192.168.12.2         120      00:00:09
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 7

G0/1 uses key chain RIPKEYS; G0/0 has no key.

⁦G0/1⁩ RIPKEYS بەکار دەهێنێت؛ ⁦G0/0⁩ نییە.

Lineدێڕی 10

R2 (192.168.12.2) is a source of routes, so its updates are accepted.

⁦R2 (192.168.12.2)⁩ سەرچاوەی ڕێگەیە، بۆیە نوێکردنەوەکانی وەردەگیرێن.

debug ip rip: one good update, one rejected (timestamps removed)debug ip rip: نوێکردنەوەیەکی دروست، یەکێکی ڕەتکراوە (کاتەکان لابراون)TEXT
R1#debug ip rip
RIP protocol debugging is on
RIP: received packet with MD5 authentication
RIP: received v2 update from 192.168.12.2 on GigabitEthernet0/1
     192.168.2.0/24 via 0.0.0.0 in 1 hops
RIP: ignored v2 packet from 192.168.12.66 (invalid authentication)
R1#undebug all
All possible debugging has been turned off
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 3-5

R2's update passes the MD5 check and is used.

نوێکردنەوەی ⁦R2⁩ لە پشکنینی ⁦MD5⁩ دەردەچێت و بەکار دێت.

Lineدێڕی 6

A packet without the right key — a rogue device or a neighbour with a wrong key-string, key number or mode.

بێ دروست — ئامێرێکی نەناسراو یان دراوسێیەک بە ⁦key-string⁩، ژمارەی یان شێوازی هەڵە.

Passive interfaces: receive, but do not spreadنێوبەستە ناچالاکەکان: وەرگرە، بەڵام بڵاوی مەکەرەوە

By default RIP sends updates out of every interface that a network command covers — also R1's G0/0, where only PCs live. Nobody there needs them: they waste bandwidth, every PC has to receive them, and anyone on that LAN can read the router's whole table. passive-interface stops the sending. In RIP a passive interface still listens: it receives updates and adds them to the table. Its network is still advertised to the other routers through the other interfaces. In short: “receive information, but do not spread it” — passive is the opposite of active.

بە بنەڕەت لە هەموو ئەو نوێکردنەوە دەنێرێت کە network دەیانگرێتەوە — هەروەها ⁦G0/0⁩ـی ⁦R1⁩، کە تەنیا PC لەوێیە. لەوێ کەس پێویستی پێیان نییە: بە فیڕۆ دەدەن، هەموو PCـێک دەبێت وەریانبگرێت و هەر کەسێک لەسەر دەتوانێت هەموو خشتەی بخوێنێتەوە. passive-interface ناردن ڕادەگرێت. لە هێشتا گوێ دەگرێت: نوێکردنەوە وەردەگرێت و دەیخاتە خشتەکەوە. هێشتا لە ڕێی ترەوە بە تر دەناسێنرێت. بە کورتی: «زانیاری وەرگرە، بەڵام بڵاوی مەکەرەوە» — passive پێچەوانەی activeـە.

Definitionپێناسە

An interface on which a routing protocol sends no updates or hellos (passive-interface g0/1), usually one facing a LAN with no routers; its network is still advertised and data still flows through it.

کە لەسەری هیچ نوێکردنەوە و نانێرێت (passive-interface g0/1)، زۆرجار ئەوەی بەرەو دەڕوانێت کە تێدا نییە؛ ڕایەڵەکەی هێشتا ڕادەگەیەنرێت و هێشتا پێیدا تێدەپەڕێت.

PC1 and PC3 hang on SW1, which is joined to R1 G0/0; R1 G0/1 is joined to R2. An update towards the PCs is crossed out: 'passive: no updates to the PCs'. Between R1 and R2 updates flow both ways, and 192.168.1.0/24 is still advertised to R2. Caption: receive, but do not spread.PC1 و PC3 بە SW1ـەوە بەستراون کە بە R1 G0/0ـەوە بەستراوە؛ R1 G0/1 بە R2ـەوە بەستراوە. نوێکردنەوەیەک ڕووەو PCـەکان هێڵی بەسەردا هاتووە: «ناچالاک: هیچ نوێکردنەوەیەک بۆ PCـەکان». لە نێوان R1 و R2دا نوێکردنەوە بە هەردوو ئاڕاستە دەڕوات و 192.168.1.0/24 هێشتا بە R2 دەناسێنرێت. ژێرنووس: وەرگرە، بەڵام بڵاوی مەکەرەوە.
Quiet towards the PCs, talkative towards the routers.بێدەنگ ڕووەو PCـەکان، قسەکەر ڕووەو .CêIT

Configuring passive interfacesڕێکخستنی نێوبەستە ناچالاکەکان

passive-interface is a router-mode command. Name one interface, or make all interfaces passive with passive-interface default and then switch on only the router links with no passive-interface. The second way suits a router with many LAN interfaces: an interface added later stays quiet until you allow it.

passive-interface باری routerـە. ناوی یەک بنووسە، یان بە passive-interface default هەموو ناچالاک بکە و پاشان بە no passive-interface تەنیا بەستەرەکانی هەڵبکەرەوە. ڕێگای دووەم بۆ دەگونجێت کە چەندین هەیە: کە دواتر زیاد دەکرێت بێدەنگ دەمێنێتەوە تا ڕێگەی پێ دەدەیت.

Two ways to make G0/0 passiveدوو ڕێگا بۆ ناچالاککردنی ⁦G0/0⁩TEXT
R1(config)#router rip
R1(config-router)#passive-interface g0/0
R1(config-router)#end

! or, on a router with many LAN interfaces:
R1(config)#router rip
R1(config-router)#passive-interface default
R1(config-router)#no passive-interface g0/1
R1(config-router)#end
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 7-8

Everything passive, then G0/1 — the link to R2 — talks again.

هەموو ناچالاک، پاشان ⁦G0/1⁩ — بەستەرەکە بۆ ⁦R2⁩ — دووپاتە قسە دەکات.

Two panels of R1 with four interfaces G0/0, G0/1, G0/2 and S0/0/0. Panel 1, passive-interface default: all four grey. Panel 2, no passive-interface g0/1: only G0/1 is green and active.دوو وێنەی R1 بە چوار نێوبەستەوە: G0/0، G0/1، G0/2 و S0/0/0. وێنەی 1، passive-interface default: هەر چواریان خۆڵەمێشی. وێنەی 2، no passive-interface g0/1: تەنیا G0/1 سەوز و چالاکە.
Default passive, then allow the router links one by one.بە بنەڕەت ناچالاک، پاشان بەستەرەکانی یەک بە یەک ڕێگە پێ بدە.CêIT
show ip protocols after passive-interface g0/0 (selected lines)show ip protocols دوای ⁦passive-interface g0/0⁩ (چەند دێڕێکی هەڵبژێردراو)TEXT
R1#show ip protocols
Routing Protocol is "rip"
    Interface             Send  Recv  Triggered RIP  Key-chain
    GigabitEthernet0/1    2     2                    RIPKEYS
  Passive Interface(s):
    GigabitEthernet0/0
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 5-6

G0/0 has left the list of sending interfaces and appears under Passive Interface(s).

⁦G0/0⁩ لە لیستی دەرچووە و لە ژێر ⁦Passive Interface(s)⁩ دەردەکەوێت.

passive-interface in other protocols, and what it is not⁦passive-interface⁩ لە پرۆتۆکۆڵەکانی تردا و ئەوەی نییە

The same command exists in OSPF and EIGRP, with a stronger effect: they find neighbours with Hello packets, so a passive interface sends no Hellos, forms no neighbour and learns nothing there. In every protocol its network is still advertised. Passive interfaces in OSPF are configured this way. And passive-interface is not a tool against routing loops: loops are prevented by split horizon, route poisoning, hold-down timers and the hop limit (stopping loops). It is a tool for security and less traffic.

هەمان لە و هەیە، بە کاریگەرییەکی بەهێزتر: ئەوان بە دراوسێ دەدۆزنەوە، بۆیە هیچ Helloـیەک نانێرێت، هیچ دراوسێیەک دروست ناکات و لەوێ فێری هیچ نابێت. لە هەموو هێشتا دەناسێنرێت. نێوبەستە ناچالاکەکان لە OSPFـدا بەم شێوەیە ڕێک دەخرێن. ⁦passive-interface⁩ ئامرازێک نییە دژی : ئەڵقەکان بە ، ، و سنووری ڕێگرییان لێ دەکرێت (ڕاگرتنی ئەڵقەکانی ڕێدۆزی). ئامرازێکە بۆ ئاسایش و هاتوچۆی کەمتر.

Two panels. RIP: sends no updates (cross), still receives and learns (tick), its network is still advertised (tick). OSPF and EIGRP: sends no Hello packets (cross), no neighbour forms there (cross), its network is still advertised (tick). In every protocol use it on interfaces that face only PCs and servers.دوو وێنە. RIP: هیچ نوێکردنەوەیەک نانێرێت (✗)، هێشتا وەردەگرێت و فێر دەبێت (✓)، ڕایەڵەکەی هێشتا دەناسێنرێت (✓). OSPF و EIGRP: هیچ پاکێتێکی سڵاو نانێرێت (✗)، هیچ دراوسێیەک لەوێ دروست نابێت (✗)، ڕایەڵەکەی هێشتا دەناسێنرێت (✓). لە هەموو پرۆتۆکۆڵێکدا لەسەر ئەو نێوبەستانە بەکاری بهێنە کە تەنیا ڕووەو PC و ڕاژەکارن.
Same command, different strength.هەمان ، هێزی جیاواز.CêIT

The whole lab on both routersهەموو تاقیگەکە لەسەر هەردوو ڕێدۆز

Here is the complete, corrected configuration for the two routers: the key chain in global mode, authentication on the interface, RIP with passive interfaces — and the save at the end. Type it on R1, then on R2, and check with show ip protocols, debug ip rip and a ping from PC1 to PC2.

ئەمە تەواو و ڕاستکراوەی هەردوو : لە باری گشتیدا، لەسەر ، بە — و پاشەکەوت لە کۆتاییدا. لەسەر ⁦R1⁩ بینووسە، پاشان لەسەر ⁦R2⁩. ئینجا بە show ip protocols، debug ip rip و لە ⁦PC1⁩ـەوە بۆ ⁦PC2⁩ بیپشکنە.

R1: complete configuration⁦R1⁩: ڕێکخستنی تەواوTEXT
R1>enable
R1#configure terminal
R1(config)#key chain RIPKEYS
R1(config-keychain)#key 1
R1(config-keychain-key)#key-string Rip-Key-2026
R1(config-keychain-key)#exit
R1(config-keychain)#exit
R1(config)#interface g0/1
R1(config-if)#ip rip authentication mode md5
R1(config-if)#ip rip authentication key-chain RIPKEYS
R1(config-if)#exit
R1(config)#router rip
R1(config-router)#version 2
R1(config-router)#no auto-summary
R1(config-router)#network 192.168.1.0
R1(config-router)#network 192.168.12.0
R1(config-router)#passive-interface default
R1(config-router)#no passive-interface g0/1
R1(config-router)#end
R1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
R2: the same, with its own LAN⁦R2⁩: هەمان شت، بە ڕایەڵە ناوچەییەکەی خۆیەوەTEXT
R2>enable
R2#configure terminal
R2(config)#key chain RIPKEYS
R2(config-keychain)#key 1
R2(config-keychain-key)#key-string Rip-Key-2026
R2(config-keychain-key)#exit
R2(config-keychain)#exit
R2(config)#interface g0/1
R2(config-if)#ip rip authentication mode md5
R2(config-if)#ip rip authentication key-chain RIPKEYS
R2(config-if)#exit
R2(config)#router rip
R2(config-router)#version 2
R2(config-router)#no auto-summary
R2(config-router)#network 192.168.2.0
R2(config-router)#network 192.168.12.0
R2(config-router)#passive-interface default
R2(config-router)#no passive-interface g0/1
R2(config-router)#end
R2#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
Explain the codeڕوونکردنەوەی کۆدەکە
Lineدێڕی 5

Same key number and key-string as R1.

هەمان ژمارەی و ⁦key-string⁩ وەک ⁦R1⁩.

Lineدێڕی 15

R2 advertises its own LAN, 192.168.2.0.

⁦R2⁩ خۆی، ⁦192.168.2.0⁩، دەناسێنێت.

Beyond MD5: what modern routing protocols useلە ⁦MD5⁩ بەولاوە: پرۆتۆکۆڵەکانی ڕێدۆزی نوێکان چی بەکار دەهێنن

Keyed MD5 for RIPv2 dates from the 1990s. RFC 4822 (2007) replaced it in the standard with HMAC-SHA authentication — HMAC-SHA-1, -256, -384 and -512 — and added a sequence number so an attacker cannot simply replay an old update. Its authors wanted networks to move away from keyed MD5 quickly. Cisco IOS and IOS XE still offer only plain text and MD5 for RIP (as of November 2026). Other protocols do better: OSPFv2 can use HMAC-SHA (RFC 5709) through a key chain, OSPFv3 uses an HMAC-SHA authentication trailer (RFC 7166) or IPsec, and EIGRP in named mode offers HMAC-SHA-256. Whichever you use, it authenticates updates; it does not encrypt them.

⁦MD5⁩ـی بە بۆ ⁦RIPv2⁩ هی ساڵانی ⁦1990⁩ـەکانە. ⁦RFC 4822⁩ ⁦(2007)⁩ لە ستانداردەکەدا بە ⁦HMAC-SHA⁩ گۆڕییەوە — ⁦HMAC-SHA-1⁩، ⁦-256⁩، ⁦-384⁩ و ⁦-512⁩ — و زیاد کرد بۆ ئەوەی نەتوانێت بە سادەیی نوێکردنەوەیەکی کۆن دووپاتە بنێرێتەوە (). نووسەرانی دەیانویست بە خێرایی لە ⁦MD5⁩ـی بە دوور بکەونەوە. Cisco IOS و IOS XE هێشتا بۆ تەنیا و ⁦MD5⁩ پێشکەش دەکەن (تا تشرینی دووەمی ⁦2026⁩). تر باشترن: ⁦OSPFv2⁩ دەتوانێت لە ڕێی ⁦HMAC-SHA⁩ بەکار بهێنێت ⁦(RFC 5709)⁩، ⁦OSPFv3⁩ کۆتاییەکی ⁦HMAC-SHA (RFC 7166)⁩ یان IPsec بەکار دەهێنێت و لە ⁦named mode HMAC-SHA-256⁩ پێشکەش دەکات. هەر کامیان بەکار بهێنیت، نوێکردنەوەکان دەسەلمێنێت؛ نوێکردنەوەکان ناکات.

A table of routing-update authentication options in 2026. RIPv2 on Cisco IOS: text, MD5. RIPv2 standard (RFC 4822): HMAC-SHA-1/256/384/512. OSPFv2 (RFC 5709): MD5, HMAC-SHA. OSPFv3 (RFC 7166, IPsec): HMAC-SHA trailer. EIGRP named mode: MD5, HMAC-SHA-256. Pick the strongest option both neighbours support; none of them encrypts the routes.خشتەیەکی بژاردەکانی پشتڕاستکردنەوەی ناسنامەی نوێکردنەوەی ڕێگەکان لە 2026دا. RIPv2 لەسەر Cisco IOS: text، MD5. ستانداردی RIPv2 (RFC 4822): HMAC-SHA-1/256/384/512. OSPFv2 (RFC 5709): MD5، HMAC-SHA. OSPFv3 (RFC 7166، IPsec): HMAC-SHA trailer. EIGRP named mode: MD5، HMAC-SHA-256. بەهێزترین بژاردە هەڵبژێرە کە هەردوو دراوسێ پشتگیری دەکەن؛ هیچیان شفرەکردنی ڕێگەکان ناکەن.
Use the strongest option both neighbours support.بەهێزترین بژاردە بەکار بهێنە کە هەردوو دراوسێ پشتگیری دەکەن.CêIT

HMAC is a message authentication code: a hash computed with a secret key in a careful two-step way, much harder to attack than putting the key next to the message. RIP itself is rare in real networks today; the OSPF and EIGRP lessons show protocols that companies use.

HMAC : هاشێک کە بە نهێنی بە شێوەیەکی وردی دوو هەنگاوی دەژمێردرێت، زۆر قورسترە بۆ هێرشکردن لە دانانی لە تەنیشت پەیامەکە. خودی ئەمڕۆ لە کەمە؛ وانەکانی OSPF و EIGRP ئەو پیشان دەدەن کە کۆمپانیاکان بەکاریان دەهێنن.

Common mistakesهەڵە باوەکان

Common mistake: a password under router ripهەڵەی باو: تێپەڕەوشە لە ژێر router ripTEXT
R1(config)#router rip
R1(config-router)#password MyPassword
                  ^
% Invalid input detected at '^' marker.
  • Different key numbers or key-strings on the two neighbours (MD5): both ignore each other's updates.
  • Forgetting mode md5: the key travels in plain text.
  • Lifetimes with a wrong clock or no overlap: keys expire too early or both routers change at different moments.
  • Thinking lifetimes limit routes or prevent loops: they only limit when a key is used.
  • Making the router link passive (for example passive-interface default without no passive-interface g0/1): R2 stops hearing R1 and the routes disappear.
  • Calling MD5 strong encryption: it is an old hash, broken for collisions, and it encrypts nothing.
  • ژمارەی یان ⁦key-string⁩ـی جیاواز لەسەر دوو دراوسێکە ⁦(MD5)⁩: هەردووکیان نوێکردنەوەکانی یەکتر پشتگوێ دەخەن.
  • لەبیرکردنی mode md5: بە دەگوازرێتەوە.
  • ماوە بە کاتژمێری هەڵە یان بێ هاوبەشی: زوو بەسەر دەچن یان هەردوو لە کاتی جیاوازدا دەگۆڕن.
  • وابزانیت ماوەکان ڕێگەکان سنووردار دەکەن یان ڕێگری لە ئەڵقە دەکەن: تەنیا سنووری کاتی بەکارهێنانی دادەنێن.
  • ناچالاککردنی بەستەری (بۆ نموونە passive-interface default بەبێ no passive-interface g0/1): ⁦R2⁩ ئیتر گوێی لە ⁦R1⁩ نابێت و ڕێگەکان نامێنن.
  • بە بەهێز ناوبردنی ⁦MD5⁩: هاشێکی کۆنە، بۆ شکاوە و هیچ ناکات.

Exercisesڕاهێنانەکان

ExerciseڕاهێنانWhy authenticate?بۆچی پشتڕاستکردنەوەی ناسنامە؟

In three sentences, explain what RIP authentication protects a network against and why it matters more in a large network.

بە سێ ڕستە ڕوونی بکەرەوە لە چی دەپارێزێت و بۆچی لە گەورەدا گرنگترە.

Show answerوەڵامەکە پیشان بدە

Without authentication a router believes every update it hears, so a rogue or misconfigured router can inject false routes and steer or drop traffic. With a shared key, only routers that prove they know the key are believed. A large network has more routers and more links where such a device can appear, so the risk is bigger.

بێ باوەڕ بە هەموو نوێکردنەوەیەک دەکات کە دەیبیستێت، بۆیە نەناسراو یان هەڵە ڕێکخراو دەتوانێت ڕێگەی هەڵە بخزێنێتە ناوەوە و هاتوچۆ ئاڕاستە بکات یان فڕێی بدات. بە هاوبەش، تەنیا ئەو دەیسەلمێنن دەزانن باوەڕیان پێ دەکرێت. گەورە و بەستەری زیاتری هەیە کە ئامێرێکی وا لێیان دەربکەوێت، بۆیە مەترسییەکە گەورەترە.

ExerciseڕاهێنانFix the configurationڕێکخستنەکە چاک بکەرەوە

This block was meant to switch on RIP authentication between two routers over Serial0/0. Rewrite it correctly (key chain MyKeyChain, key 1, key-string MySecretKey, MD5, networks 10.0.0.0 and 192.168.1.0; only Serial0/0 should send updates).

ئەم بلۆکە بۆ هەڵکردنی لە نێوان دوو لەسەر ⁦Serial0/0⁩ نووسرابوو. بە دروستی بینووسەوە ( MyKeyChain، 1، ⁦key-string MySecretKey⁩، ⁦MD5⁩، ⁦10.0.0.0⁩ و ⁦192.168.1.0⁩؛ تەنیا ⁦Serial0/0⁩ دەبێت نوێکردنەوە بنێرێت).

The broken blockبلۆکە هەڵەکەTEXT
router rip
 version 2
 network [NETWORK ID]
 network [NETWORK ID]
 passive-interface default
 no passive-interface Serial0/0
 password MyPassword
 authentication mode md5
 key chain MyKeyChain
  key 1
   key-string MySecretKey
   accept-lifetime 00:00:00 23:59:59
   send-lifetime 00:00:00 23:59:59
 exit
exit
Show answerوەڵامەکە پیشان بدە
AnswerوەڵامTEXT
R1(config)#key chain MyKeyChain
R1(config-keychain)#key 1
R1(config-keychain-key)#key-string MySecretKey
R1(config-keychain-key)#exit
R1(config-keychain)#exit
R1(config)#interface serial0/0
R1(config-if)#ip rip authentication mode md5
R1(config-if)#ip rip authentication key-chain MyKeyChain
R1(config-if)#exit
R1(config)#router rip
R1(config-router)#version 2
R1(config-router)#no auto-summary
R1(config-router)#network 10.0.0.0
R1(config-router)#network 192.168.1.0
R1(config-router)#passive-interface default
R1(config-router)#no passive-interface serial0/0
R1(config-router)#end
R1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]

There is no password and no authentication mode under router rip. Lifetimes are optional; if you add them they need dates, for example accept-lifetime 00:00:00 Jan 1 2026 infinite. Type the same on the other router.

هیچ password و authentication modeـێک لە ژێر router rip نییە. ماوەکان ئارەزوومەندانەن؛ ئەگەر زیادیان بکەیت ڕێکەوتیان پێویستە، بۆ نموونە accept-lifetime 00:00:00 Jan 1 2026 infinite. هەمان شت لەسەر تر بنووسە.

ExerciseڕاهێنانTrue or false?ڕاست یان هەڵە؟

Mark each statement true or false and correct the false ones: (a) send-lifetime sets how long routes given with network are advertised. (b) accept-lifetime and send-lifetime prevent routing loops. (c) A passive RIP interface still receives updates. (d) Key numbers can be 0–65535 only.

هەر دەستەواژەیەک بە ڕاست یان هەڵە دیاری بکە و هەڵەکان ڕاست بکەرەوە: (أ) ⁦send-lifetime⁩ دیاری دەکات ئەو ڕێگانەی بە network دراون چەند دەناسێنرێن. (ب) ⁦accept-lifetime⁩ و ⁦send-lifetime⁩ ڕێگری لە دەکەن. (ج) هێشتا نوێکردنەوە وەردەگرێت. (د) ژمارەی تەنیا دەتوانن ⁦0–65535⁩ بن.

Show answerوەڵامەکە پیشان بدە
  • (a) False: send-lifetime limits when a key signs outgoing updates.
  • (b) False: they only plan key changes; split horizon, poisoning, hold-down and the hop limit fight loops.
  • (c) True: it does not send, but it still listens.
  • (d) False: Cisco IOS accepts key numbers from 0 to 2147483647.
  • (أ) هەڵە: ⁦send-lifetime⁩ سنووری کاتی واژووکردنی نوێکردنەوە دەرچووەکان بە دادەنێت.
  • (ب) هەڵە: تەنیا گۆڕینی پلان دەکەن؛ ، ، و سنووری دژی ئەڵقە دەجەنگن.
  • (ج) ڕاست: نانێرێت، بەڵام هێشتا گوێ دەگرێت.
  • (د) هەڵە: Cisco IOS ژمارەی لە 0 تا ⁦2147483647⁩ وەردەگرێت.
ExerciseڕاهێنانA router with many LANsڕێدۆزێک بە چەندین ڕایەڵەی ناوچەیی

R3 runs RIPv2. G0/0, G0/1 and G0/2 face only PCs; S0/0/0 goes to R4. Write the RIP commands that keep the PC LANs quiet with as few lines as possible, and say whether the three LAN networks are still advertised to R4.

⁦R3 RIPv2⁩ جێبەجێ دەکات. ⁦G0/0⁩، ⁦G0/1⁩ و ⁦G0/2⁩ تەنیا ڕووەو PCـن؛ ⁦S0/0/0⁩ دەچێت بۆ ⁦R4⁩. بنووسە کە PC بە کەمترین دێڕ بێدەنگ دەکەن و بڵێ ئایا سێ هێشتا بە ⁦R4⁩ دەناسێنرێن.

Show answerوەڵامەکە پیشان بدە
AnswerوەڵامTEXT
R3(config)#router rip
R3(config-router)#passive-interface default
R3(config-router)#no passive-interface s0/0/0
R3(config-router)#end
R3#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]

Yes: passive stops only the updates on those interfaces; their networks (covered by network commands) are still advertised to R4 through S0/0/0.

بەڵێ: تەنیا نوێکردنەوەکانی سەر ئەو ڕادەگرێت؛ (کە network دەیانگرێتەوە) هێشتا لە ڕێی ⁦S0/0/0⁩ـەوە بە ⁦R4⁩ دەناسێنرێن.

ExerciseڕاهێنانRead the debug outputدەرخستەی debug بخوێنەرەوە

After you configured R1, debug ip rip keeps printing RIP: ignored v2 packet from 192.168.12.2 (invalid authentication). List four things to check on R1 and R2.

دوای ئەوەی ⁦R1⁩ـت ڕێک خست، debug ip rip بەردەوام دەنووسێت RIP: ignored v2 packet from 192.168.12.2 (invalid authentication). چوار شت ڕیز بکە کە دەبێت لەسەر ⁦R1⁩ و ⁦R2⁩ بیپشکنیت.

Show answerوەڵامەکە پیشان بدە
  • The key-string is identical (spaces and capitals count).
  • The key number is the same (MD5 mode).
  • Both interfaces use the same mode (md5 on both, not text on one side).
  • The key is valid now on both routers: check the lifetimes and the clocks (show clock, show key chain).
  • ⁦key-string⁩ وەک یەکە ( و پیتی گەورە دەژمێردرێن).
  • ژمارەی هەمانە (شێوازی ⁦MD5⁩).
  • هەردوو هەمان شێواز بەکار دەهێنن (⁦md5⁩ لەسەر هەردووکیان، نەک text لە لایەک).
  • ئێستا لەسەر هەردوو دروستە: ماوەکان و کاتژمێرەکان بپشکنە (show clock، show key chain).

Summaryکورتە

  • Without authentication, RIP believes any update; a rogue router can inject routes and steal or drop traffic.
  • RIPv2 supports authentication (RIPv1 does not): plain text (default, key visible) or MD5 (only a digest travels).
  • Keys live in a global key chain (key chain → key 1 → key-string); authentication is set per interface (ip rip authentication mode md5, ip rip authentication key-chain) — never under router rip.
  • Key number, key-string and mode must match on both neighbours; the chain name may differ.
  • accept-lifetime and send-lifetime set when a KEY is accepted and used — for changing keys with an overlap; not for routes, not against loops.
  • passive-interface stops updates towards PC-only LANs; in RIP the interface still listens and its network is still advertised; passive-interface default + no passive-interface.
  • Verify with show ip protocols (Key-chain column, Passive Interface(s)) and debug ip rip (invalid authentication).
  • MD5 is legacy and encrypts nothing; RFC 4822 defines HMAC-SHA for RIPv2, and OSPF and EIGRP offer SHA options.
  • بێ ، باوەڕ بە هەر نوێکردنەوەیەک دەکات؛ نەناسراو دەتوانێت ڕێگە بخزێنێتە ناوەوە و هاتوچۆ بدزێت یان فڕێی بدات.
  • ⁦RIPv2⁩ پشتگیریی دەکات (⁦RIPv1⁩ ناکات): (بنەڕەت، دیارە) یان ⁦MD5⁩ (تەنیا دەگوازرێتەوە).
  • لە گشتیدان (key chain ← key 1 ← key-string)؛ بۆ هەر دادەنرێت (ip rip authentication mode md5، ip rip authentication key-chain) — هەرگیز لە ژێر router rip.
  • ژمارەی ، ⁦key-string⁩ و شێواز دەبێت لەسەر هەردوو دراوسێ وەک یەک بن؛ ناوی زنجیرەکە دەکرێت جیاواز بێت.
  • ⁦accept-lifetime⁩ و ⁦send-lifetime⁩ دیاری دەکەن کەی وەردەگیرێت و بەکار دێت — بۆ گۆڕینی بە ماوەیەکی هاوبەش؛ نەک بۆ ڕێگەکان، نەک دژی ئەڵقە.
  • ⁦passive-interface⁩ نوێکردنەوە ڕووەو ئەو ڕادەگرێت کە تەنیا PCـی تێدایە؛ لە هێشتا گوێ دەگرێت و هێشتا دەناسێنرێت؛ passive-interface default + no passive-interface.
  • بە show ip protocols (ستوونی ⁦Key-chain⁩، ⁦Passive Interface(s)⁩) و debug ip rip ⁦(invalid authentication)⁩ بیپشکنە.
  • ⁦MD5⁩ کۆنە و هیچ ناکات؛ ⁦RFC 4822⁩ بۆ ⁦RIPv2 HMAC-SHA⁩ دیاری دەکات و و بژاردەی SHA پێشکەش دەکەن.

Next: Route Summarization — one route for many networks.

دواتر: ڕاپوختکردن — یەک ڕێگە بۆ چەندین .

Lesson complete!وانەکە تەواو بوو!

Well done. Review the key terms, then go on to the next lesson.دەستخۆش. سەیرێکی زاراوە سەرەکییەکان بکەرەوە، پاشان بڕۆ بۆ وانەی داهاتوو.

Key termsزاراوە سەرەکییەکان

Next lessonوانەی داهاتوو

Route Summarizationڕاپوختکردن

References and further readingسەرچاوەکان و خوێندنەوەی زیاتر

This lecture is a first edition. The Kurdish text and terminology are waiting for review by Kurdish IT teachers.ئەم وانەیە چاپی یەکەمە. دەقە کوردییەکە و زاراوەکانی چاوەڕێی پێداچوونەوەی مامۆستایانی کوردی بواری IT ن.

Appearanceڕووکار

Modeدۆخ
Styleشێواز
Coloursڕەنگەکان

Saved on this device only.تەنیا لەسەر ئەم ئامێرە پاشەکەوت دەکرێت.