Skip to content

Instantly share code, notes, and snippets.

View nirui's full-sized avatar
Slow to respond

R+ nirui

Slow to respond
View GitHub Profile
package main
import (
"fmt"
"time"
)
type s struct {
s []sData
}
package main
import (
"fmt"
"time"
)
type s struct {
s []sData
}
package main
import (
"fmt"
"time"
)
type s struct {
s []*s
}
struct Test {
n: usize,
}
struct Test2<'a> {
n_borrow: &'a usize,
}
impl Test {
pub fn return_n(&self) -> Test2 {
<?xml version="1.0" encoding="utf-8"?>
<direct>
<chain table="filter" ipv="ipv4" chain="proxy_restriction"/>
<chain table="nat" ipv="ipv4" chain="proxy_redirect"/>
<rule priority="1" table="filter" ipv="ipv4" chain="proxy_restriction">-p tcp --sport 2302 -j RETURN</rule>
<rule priority="1" table="filter" ipv="ipv4" chain="proxy_restriction">-p udp --sport 2302 -j RETURN</rule>
<rule priority="1" table="filter" ipv="ipv4" chain="proxy_restriction">-p tcp --dport 3128 -j RETURN</rule>
<rule priority="1" table="filter" ipv="ipv4" chain="proxy_restriction">-p tcp --dport 8080 -j RETURN</rule>
#!/bin/bash
# DEFAULT
iptables -P INPUT DROP
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -p tcp --dport 30001 -j ACCEPT