File tree Expand file tree Collapse file tree 5 files changed +23
-2
lines changed Expand file tree Collapse file tree 5 files changed +23
-2
lines changed Original file line number Diff line number Diff line change @@ -164,11 +164,12 @@ rule-providers:
164
164
- **qv2ray_schema.json:** فایل قابل استفاده در کلاینت [Qv2ray](https://github.com/Qv2ray/Qv2ray).
165
165
- **shadowrocket.conf:** فایل قابل استفاده در کلاینت [Shadowrocket](https://apps.apple.com/us/app/shadowrocket/id932747118).
166
166
167
- # # منابع
167
+ # # منابع و قدردانیها
168
168
169
169
- دامنههای ایران :
170
170
- [سازمان فناوری اطلاعات ایران](https://g2b.ito.gov.ir/index.php/site/list_ip)
171
171
- [سامانه مدیریت اینترنت مشتریان شرکت مخابرات ایران](https://adsl.tci.ir/panel/sites)
172
+ - [انجمن لیست دامنه v2fly](https://github.com/v2fly/domain-list-community)
172
173
- [لیست شخصی][link-custom]
173
174
- تبلیغات :
174
175
- [PersianBlocker](https://github.com/MasterKia/PersianBlocker) (لایسنس AGPL-3.0)
Original file line number Diff line number Diff line change @@ -181,11 +181,12 @@ go run ./ --outputdir=../
181
181
- **qv2ray_schema.json:** Importable json schema that can be used in [Qv2ray](https://github.com/Qv2ray/Qv2ray).
182
182
- **shadowrocket.conf:** Importable conf file that can be used in [Shadowrocket](https://apps.apple.com/us/app/shadowrocket/id932747118).
183
183
184
- ## Source
184
+ ## Sources & Acknowledgements
185
185
186
186
- Iran Domains:
187
187
- [ITO GOV](https://eservices.ito.gov.ir/page/iplist) - [Mirror](https://github.com/bootmortis/ito-gov-mirror)
188
188
- [ADSL TCI](https://adsl.tci.ir/panel/sites)
189
+ - [V2fly Domain List Community](https://github.com/v2fly/domain-list-community)
189
190
- [Custom List][link-custom]
190
191
- ADs:
191
192
- [PersianBlocker](https://github.com/MasterKia/PersianBlocker) (AGPL-3.0 License)
Original file line number Diff line number Diff line change 1
1
# https://eservices.ito.gov.ir/page/iplist
2
2
g2b_gov_url = "https://raw.githubusercontent.com/bootmortis/ito-gov-mirror/main/out/domains.csv"
3
3
ads_url = "https://raw.githubusercontent.com/MasterKia/PersianBlocker/main/PersianBlockerHosts.txt"
4
+ v2fly_base_url = "https://raw.githubusercontent.com/v2fly/domain-list-community/master/data/"
4
5
5
6
# input files
6
7
adsl_tci_file_path = "src/data/adsl_tci.txt"
Original file line number Diff line number Diff line change @@ -33,3 +33,20 @@ def ads() -> Iterable[str]:
33
33
ads = filter (utils .is_not_ip , ads )
34
34
ads = filter (utils .is_url , ads )
35
35
return sorted (ads )
36
+
37
+ def v2fly (filename = "category-ir" ) -> Iterable [str ]:
38
+ resp = requests .get (consts .v2fly_base_url + filename )
39
+ resp .raise_for_status ()
40
+
41
+ domains = []
42
+ for line in resp .text .splitlines ():
43
+ line = re .sub (r'(?m)^\s*#.*\n?' , '' , line )
44
+ if line .startswith ("include:" ):
45
+ domains .extend (v2fly (line .split (":" )[1 ]))
46
+ else :
47
+ domains .append (line )
48
+
49
+ domains = (domain .strip () for domain in domains if domain .strip () != '' )
50
+ domains = filter (utils .is_not_ip , domains )
51
+ domains = filter (utils .is_url , domains )
52
+ return sorted (domains )
Original file line number Diff line number Diff line change @@ -44,6 +44,7 @@ def collect_and_clean_domains(*domain_set: Iterable[Iterable[str]]) -> Iterable[
44
44
all_domains = collect_and_clean_domains (
45
45
get_domians .g2b_ito_gov (),
46
46
get_domians .adsl_tci (),
47
+ get_domians .v2fly (),
47
48
)
48
49
49
50
# Divide info
You can’t perform that action at this time.
0 commit comments