-   Linux - Networking (
-   -   What does " / " mean? (

sourav garai 05-01-2012 03:11 AM

What does " / " mean?
There was a command i found in a book. This is a single command.

iptables -A FORWARD -m tcp -p tcp -s 0/0 --sport 80 -d /
--syn -j DROP

What does " / " mean? The " / " just before --syn.
Is it necessary to give?

em31amit 05-01-2012 03:17 AM

it should "\" not "/". "\" is just to switch new line in command continuation . it should not be "/" here. It may be they have typed it wrong.

sourav garai 05-01-2012 03:25 AM

Ya .. i guessed it was for switching to a new line. Can u please suggest a link where i can read more about this?? In the book they have used " / " in all line switching. So i am little confused.

em31amit 05-01-2012 03:32 AM

Start with Beginner's guide and understand concepts how to make the rules and logic and MAN pages


and At the last.. google is the best option :D

fukawi1 05-01-2012 03:40 AM

Quote: Escape Character

A non-quoted backslash ‘\’ is the Bash escape character. It preserves the literal value of the next character that follows, with the exception of newline. If a \newline pair appears, and the backslash itself is not quoted, the \newline is treated as a line continuation (that is, it is removed from the input stream and effectively ignored).

Searching the above document for "backslash" will explain all the possible uses of the backslash character as far as BASH is concerned.

sourav garai 05-01-2012 04:07 AM

So thats an escape character.
Thanks again.

All times are GMT -5. The time now is 07:22 PM.