-
Notifications
You must be signed in to change notification settings - Fork 19
/
短视频解析.js
23 lines (22 loc) · 14.2 KB
/
短视频解析.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/**
* @author Yuheng | onz3v
* @name 短视频解析
* @origin onz3v
* @version 1.0.0
* @description 短视频解析 临时只支持抖音
* @rule ^(jx) ([\s\S]+)$
* @rule https:\/\/v\.douyin\.com\/(.+)
* @admin false
* @public true
* @priority 999
* @disable false
*/
/**
* 如需下载背景音乐请设置无界 set system Host http://ip:port
* 下载原理是先下载到服务器然后再回复,后续如果有好方法会优化
*/
const request = require('request');
const fs = require('fs');
const path = require('path');
const HDQ_UA = require('./lib/USER_AGENTS')
/** Code Encryption Block[419fd178b7a37c9eae7b7426c4a04203d45e01cd4c8344ffddd8d874f1b64a318191f9514b98d644c03366d9e66250657c852ae9d8fa040df26bd8a44f5863c890c30f6ca170046d72422adb9d2c5b12bdb3960487a39560a3d26b025b5b8c3da2dc25865c73a7b91612560417eb674b642239a894331d4779eb59b65024a4f8129de8787c7fcbe087a4092d447c1a8a77405da892b95409748991220dff632d10dd00ef50880ed3b54ef7a362ea8dcff9724b075336db182925f92d704068567615c7d1a3fabbdc9d4f69dd8da055115263fef1a2a5819ce32cb81a26eadb20942f4b9cf8d630fc353dfae64aa604590ee5cc09f81caa22de8e7a87ffa0c6c7f999e3c75441748df45f7b89ac8c0bb18589ac0c1352e0a2f8cd434213e5bda7bfd82be615726c28390d557adad469b807b78e0b4f6db8de79201318489b84924afbbd1a8adee327532fd6c4640b770e576d58bfaacc964eea0c6b6ca2a662299d83798be842ebd1588fa0783048bf9dba9470f475166bd4133ed2af406eaa5a9a9f089b6f7eb2395135939181fc2b41b8e065b9f1f8c338deff271004194e919daa9d05c4815413dff34797558ce9fbc49790fd101cdeddadb7337075067b6cdd9adcac127a82d43475e57bf74f2876432e85343743e6ae95b84b51ee8c4c71451a7e9477f8e2282f0efcdb1ff9db5293928330af5d732e98880df103157b636da47f35d7a2e517e0fc4296e73bd2f23966326aa96dc0d35089794e99c43665c1f6ef5c8ef74fa4ee6357a8adcc70bcda0a301b970a96631830372a0383a48c882c06a45c51422fb20a6015e11a5685d5af1e74a4b0d3ebf65f32ad9e38403224097c85f1d14fb5d73ce7638380add727eb247f06ef4992a582108246a85ce9d4c3fe46591ca533c4380055536940154970e4bd6e513f3761030e9742868a92e10866c9cbefcd05ceda2f9c3da3bd48b600ce67df20ada51916a5bd1d363ef7cefc45118510560fc28ed6c5011415f1d803a19f1fdbc7217d4307124b9f01427b8d0675a0e2f37257eac4e1c710a2e131b8b69965a04e36fccaae2f4e4bb5e11a15e2c01d3a1f766ef066397ab16263fa136e3a75d6c0b121644856246d0be251b90412caa1a4ab2b6366047eb602b57d3cdf8ce4039e8bad6aca5831d627c72c602cc66369d061ac965569a2034802e5fe08ee0c185bba93adeb31c812700daf8ae2a1471fa0b142545fc007fc98a6588e21fd776989a1200e61a12fe71aea6a6d64978f536810bfea987f502eb955cf6196afb06cb8f12f55033f0fc92b0e2bfb5376b35d82a2d56c75ea06ac01a5c9de8d3540c59cedee22409ec028dfc4607a6593032f9ff7550cf19829d3a33d9ae037fefd02d2946fbc50ddd3985427bc4e1775d1bf0bbe551fa01a069121a2548d3c17d5f6974493704ef84c5bc145d669678accb8bf31ae04a36c55e37c02d9c46d3b97b2210d051f6f6d6166879f2bece45fd3afbd5995d8e6925eb6e1ae365fa2793d66a9caccfb3caf68f21d895d938e82db3b629de7ddc94898d7e34f5b1f4b15ca6107c3ba12fb73ca07ea125f5b78cdaf5a2d4d399ae8cd97128a29a945a19e515052a1bf8f8ef9b7b392bc4702ca427433caee5438c88d70799ce373ad3d8c65a30b15209750df59a3577de3e4b9257030294808666f2a0a0cd393aa7a14586736e118863e7f3b36bbfcd95a22a225e78d0e2bc9223c39971603b2c191f025c1f0ee2577ebfd8aebfc625faea7f264468c0240e97306a80e47c813970f4d6e7aaa3113affbfa6081c2a060f6198d7659165a4fdf5153911d50e5b84283dcf153c470dc09dcfc81c9f57cd3fe1eb07e8e98cb9f7b3548121a2ff0b5da08aaeee2818ef636c01df0ba1e63f2c8c7a314aad11ecaafcb2d9c67a649309efea52f1965e64b07437d503ac2eb635e8b69c27dbcf451495d8d92149c29994c12b026fcbd95aa64ce2dd36037a64b3baed1ba45d00db2d7e220ae4cf35a9815a8116015c961987838aa082870d770679755fe5e16972225a82b7da84920a71d362f0c6fabca4feef19b0dc37f5205ad589554373748f22952788afb27ce9b7927108d8c50f00f0a98b9302a1d8c20399b3effea893850482590c295aa6f02379f70e1d5ac49c12e07afc7e55f5edb7ca2d7ddd3bf73f6e6aeca62425afdd3746bc2d9d1a1895142f77abd5da2e7b87f81d771f40811fe2ceac05bda690b4afeccac938ffc44cc71fcba3aa78260f83081e9bb437203fdb03696335cb59f2757150d1293ba70745531d943b9c7957947407394c09a9db65b173a827cdad6fdbe5a137c73e98fe483a4b07932e24795e92cca9891f16a4b7d246a1eb94af1e9563055bbb728eb1fb77cbb23363fb6d71e056cee337076557bab13571d75889c1cd33f2d3c2b92049754fe62b7d39f6a5f9500a63613d5b5d25391a76ea18e8671c213277bae53855760f8d63730473a7ebfdfadaad58747fbfe9fab084958a87f3e8ac261c6031ad32d1fd561ad6bae6c6171cbdd623611877f70427f8a7415446aa1c47aeef215767cc127594dfeab3547005e950e87a58827d622e01df82c02083e4578e36f7147729b811cddb463490aaa7da5d94e117515b4634ddff24877e919780fe9fa6fdd55851886eb4008fa34551ccf8dddfd0286749ae79c1e4e4a1d31d0035895d71d1df35d87705bca9cc7d6aa7d4aa3cb56d6c847eacc47bf52a8be43dd0377301afa06014f4ba5d744dbdff1e28f44a008da0df18db08eaefb596e0c6e752497525af9b9acefac84759d2fe306a86f8850b83fb7b46803cc3827c6ea42ccfc33b7d9608e13fa7f2e4c2853ed78c887a79f1a89de6a43f08838ea724679fcbc347967f6f84e35ec6b2ce328b6e47360cba11f39de97007378ecfaef6a11eeff82fb93a0783342e2af7877a4d36d6ed47824dffa1cf5914df259c7e7fca30273e978250d1dd8ce83e5cb8c9e577def4bb90f27f8c65e024ddc54e6ec945f29c1090cd6ff7fc5804b1602eeefa05297fdfdeb9e5e73b23b612a142a0f199195a83b53e24623feefdae83bc944037e95e369d3315450b8600c9c5e453e3e07b9205e6ce408d5b632b68cd152d7d912333d29091f4999a753828b3138fe6122e8737eb6b15f19d853f03622bbc6d5b5ce397cd1cc236cc3cc9ac7d59ae23d77a11c818c87b7d3420f9f4e638cd205a267ccfe37e644e8127d2a234784cea22c9a4dea54b05adb4d03095c1057e75975dc004ba4e4c485881c674a8902a5710f077969e7ba47bd58c4d683a654e87070da7df9f334dfae7e69e544a3e6c941328889be7dedf01f9fce35f252e231c55f43332a73a939889e2fa2b43e4e16ef90d86325d5c104f95766c217d85cdbf0bab8d70f6e797f58f2f91fb215c79ee0f4d8f1c21e26e225d759c2aac969a87d67f0df4cf3f1d212389e2fc22a58a2fcc543950f9a7e6cd7eb6a1c3abd6371206d4e93649a1663cfcba70f0bcfc784e320fd61d51fdba401bafdfe36e08394b35443b9c7f74bf184de9696f7a21ef977551857466076553e9b8b7223318070aa104ffb959027f46faff8e411a35a4745ee1ca3946d2b1557953e5f76a5eb8869cbbd95ac83053b114b63e0069080d9c4c76ffcb5cf53cc1e8df0a15acc51f95f0361a9a6fbb613a4d351d4e18ffb380fcf78229536d55344dc51dcfbbd9b1577874b35358ab3bee021ab3e2a86654a74c5c405072de43adc83f741e67070d3f57bd72ead89801bcb644cbdfbfae067220fb9e78cd957219ce8c810034e058ace1216d3a0631ea2a933725127d4ae025c8ad1dd2c03e9f0df9c6ff023ad0852a638612c346830f6d12d97e1cfd3b78a30cfa348e307fb1b7791202b4e8a8ad5a9e903544e66e53dd2daef88e75dbf695ff7b9da9564c437e6c39534ab3de5a5a0f9606f70f8166c1513ee9e1e32877574117fe64e2a860e0ad7025086927334f1afb8f6a78e09635344300decc07b75fa185d6459415e1d233a516bfebba14376e63c1edc8b53f6bc086a9276cf1a7f733a36afcf078a676e6f15b39872ff2dffca45472c054893010143fa1781d9d9cd46e3698fee54131022f2ff28aed1c4fe5432bbccf7fd45bdd1a6799306bd49c3b46afdf697d58131c9d14ea8f9766f3ef1dd3f8de938d5eb8323d7ca509001bc36b302d54dadd012a792e353bffe975970f3ebd4f849f9046b7c0a15663ab999fca4d38f4b5f567db684e2df346441e27c143fee60f76fa76ab7258cb7414421a5cd5d8774c80bdba8573e80c41e52d390e5fff83bcd9ce40214cde3e882fc99742772411af16a39aabe28d16a1d1d4cdf54f7f5bc3ee39dbc285b51c7e6577526d8e0d1768d344c51e88f601e894d8cd14601b919e978c09b9c9ea15bc8d81c33590adf42d7dce1bed9cb04d73d28f04a38710c03226832e223c74355fb05dc0c1ffef574ab11b705096479fe4629f10e5a78d8b89fb3aacdf1d72b00dc915baa41afb572813453a215b4605afb97a2df9c327fadfd75ddb9fc75a3d0d2beb52601854f278e853805285f326af6a22ea165feaac0da006a9b7d5693b6a49f2c1282e0fdb1d2c40042adb2d518ad24885bd99b126f9f25271b8ba860b88a8003a8fd6feb108b30d65b894478f9c721bb9a1a2f4add7863571f654ec5ef3dc827a001d29d96495c1cbb909af7687c9df31e9214e07f71ef6e0940dd5395dcb55289cf593391ad62d59eb50ce78010621164abcc05e7ca79c171992cdb6f91c5bbcfdf112f168906ba1ada351f3285db4d39b4a4442e739755345544332efab1a259331293c83a96c94e819b48762a73813b70dca1a72afb1927a66ee1d5f50ec641f89f586399d1ab466781690c122fadd60deffcbe041c249b395504ed20d08421b063dcbae1dafbf4c31a5f9430a5ac51f00ce4e544182c2cbaead3a3f21562ffa9f22955b9c660568f0c94a0e02031a48c8c20b4774d453afeabbb8f5217bd6787a7003d05edaee65c43cf859344695104a9cdb0e25b98881cb03af285591d1aa506bede80bcc38682305fbcdcc3e913df4b6c2094c2c2135611732b56fd9b5c9d6e033de7fbc348cdc1266dc928d9e5b61521b5612dd6ec041787a52581b4a86b01c439dfc2a62efc1977e8e7adcc7e6a5c0272c7db954b08f843c4efa0ae5f3726fdaf0acd4990a717bf3b5d9da5ba38d9b12484fea1dd4b27533785c3a48736aaddbd90aad38cce6de3d49fd996c501597f2ae4f5bd73cb6e96fd449bf7868a75ef5415971c9214293ee269af6a55ca44cddd156073035f8a74772964552b6180592be8d77f618475eefab5a810c96b828129759703b1c87d291d5a46f571858f3084ed28c8cbbe75d92eab38bc66de3eeb997d1fa76cb270afc96ef529e34bc7693a748aa9820f525fd028eba61f893c8ef30d6eed9e05eb7ffd2ca48a79aa2a2763d2d0a39aba1c21582cdbd977582b9ad78137371c822b206fb52ee996451d04b5a088cfa9f7f14c8899ea2a35e1384c9785ca2543c6ea512f53be07ebcb67ddeee7d56a71841098bdf7157040f6cf6bd35a46bbd9e3c0aa0964213a86d1ca7255c3affb9ab72e4d13537a56407586cc29ec30cd796434036a9cd356f96eb9a7e64c11d11f27d41e361566dab682779a7b436071baa3c5be725059e087c86d5b15b3a20bb473e5ae58c80c20d7d2e308d4e9712ffd2535b013672a4e721ff3616ef48c890d62800b41c92cffeb5af6535020adfaa144fe1570c85c011506264cff976dd9b1bf2a7184ee29f54dbd3b135af8be77cba06b727d35e0e006c50ef6d3a3c601af5c848cc0752cd3cb8c625ddeff8e766a4fad7fd331e41e9ac32a42bd67fe0b80345fa323eb6b440d4a0ec763e875c74703bc2681afd493f4a1e0cef0e6b22c7390b9436c74c1f6a3170cfb86dc3a81c35d3f222cb925b2e690d46199572f272eb9075f5c22a0184c25bf15006380c5666c02ab285a03f79a0a630b87c14ce99fee74ceab5b33c227b1b5bc96fbb9e609053ea4a1660e0668965dfac546a321399174cb0aadb2e9d1476748aa470fb0e16a4536e9d20927e70a8efeec0dee032766d565128b86bb6267aa7534c0f9c0308056769353bf3bc7f44ce341e0eb30941536dc0716477cd72d346f9e97345005c9f1e62c0c7753ad793bf348855d507516582608ec7934ac113562b5329aeb315f3fab8e62474ac6b237ff16108ba7fbc7f57da727d83039960d6608d5f063edb983868a7f70755b21d6244a3528a3b6e01a2a7ea10690f4ec49d460f42eec23371ad717705f7f7ec5a3a4b7532189b93d811b66405fba72c54d14d982656858efd437e2ab1378de3e361e1d8a3937544b3a0e93876d402432932d23674e1077ca40e57e9de77530b43b2d8ba490d058d6d3ef96a521d3f4c43744b9836b5a3579442aa6efeb51e10fcd702fc8cd644e239282167758241cd685f1b8f4742114458171ef87fd57ea016c8b1572a33cb52ed9b31b98694a3eed9d09342bfdc9de7a87c963f1cd0b0f826b5b6637c2a0e1c6aab1509ee2685e7bbcefe7b99cf4aa280c26b7fd24a9c4ac4636793dcba9606336c6d6747f4c2863bfc4d662e852ef38ec793e385af8ae7059de00e1dcd792e473849233446a286daf613da2169b5ac6365eae328b53aa66824765b3add764d7f046cf83f662280b4344a5dbfb2eacfff1037c5a0ba5bde6b655040330762ddb34f5f7853f71b12bff6547d56412348874360ca54f65f0cf8d3cb57a395b5b163675339409764be2b185a30f8e0aab206609fefc9245d496dc08677427ec47a44e9bd8552081464ce7c9a2db0357d02a049fd8e405ea0e8a2d00619d5537a16a8af5171f8aef72da9966df35ac9b45bba6019212a2bc4425901abf420f1f072c076fd253c9f9729a771300d63756c317b6cc8d36647bfdbeeff42bd05d82094bd549d67005bd2495d544bef6b1dbd0f071e125dc50a99c6730d41a219c63ad37327d300c5aac42edeeb10280e274aebe15aa26c7716710ca016a8d3a71a2fe18b11d1f57999e3dcdbd67be0e632becbddeb8462e345852b8f34bc3fb576a9ee0fa78c996e6af7205ecc0fdef15b0bf318963eea1e074a3757c31a825677927ce397f82eb760c0e17aa9da1343627f34a0d9c9c7aee92e788b58f3358a7ce7027d7f3b1f5c037d0a3512a3af4072f77752dc75f3951dcd6f8b1a9de092716adca710b356b64ef4f925272ec6b58306e5aad64b148eaee5879771082ab0d9a7c325b8b34bb4eb9c74ae610b73bf5ba1ff09ebed50f21b351edead14ef91df596ea47d7983e6d81108161d0b366f6ff8843bf4fc571f6fc794c64ce188286b832bf435843b7462ef5c39266d85a3f33f01c047040b2ac695d79cb25e1aeba912c0c542670d9786050920c367813c81dcad7191990be997dc865e360df608089514a0797f47ce1a613ce21bc1f00239d0b6f9f3576cb5a7eecb0d5000e08b0750b958ec03e3ef1a48dec028566f728de64d5cfaa9d39947683c45a2f7d23608dae50bfcd441c5cdd9570eeeb578b00691db7d8a4b1ddd78a938a7d17c5da6e8a51b7f2257002473d8408e4d40b476b27d7b180ab2f75c188114c7e6d189ddcbf81c4d0ac8cd3dcf7f3cf3d64964c4d802cd143276f8346e688e65280a0af9805b41b975caa9488acfc4bd248cfc20883ae06e6e94ea50d47f37f8fc6c81c8e3e743f6121be30c8dbd7b9c241ddb01244722a52f9c74a12df1697a546e8d7267ed41b777e6326a6b231f030117f46b83258c1c2f042d5f595953ccf7ae1f9f5a165b543a1269e10fb25065fe9786ee82f410b7a1f91b97b5ed76d53088b1ce48573c3b1416115946188e940c32e40529698e18715d856858ec6d88d9dd74bf53c60c4a0b7779c4d6c5bc736db73dc086daf7c0594b4c6663b12577084732e20f1c86ca2e45b1bd88c49a1a0a8cbd5b6248f48df3771e29e56270e0dd88e0c06cdba8dc18ad6a7f33c0ec2a372fa6724ad507c67170595a6f586f753d686ac366ae2e284a52df7f51bdd474973a8e485534ad54716c7c8e664ffb4063c28c5136b59a45994e11048ea75b9f3a6354a1c300b1b92059d8a1560f7f4986eb7eb4289e7218fce35de56c73315390841510a35284de1ecb0487ec4d7f695d384cb649069c78fd75859bfe2881e93e90cffc82a65a6696aa560bc99d76b1a47d5df4b7a0c6d65196aa5018e4edcb7e529c6028680f9fdaf82d3cce00bb2314f158cc9d9cc97b32a78736bdf84be48467a7f7d93e85366fb86b3447da35e6b01a68c06c88b665f7168c2de7fca9c4cb5e0b3e4d09511e9f3602f7591d2dab8e6534d7714beaa63b28837b738fed98b8106f8568a16c8f0e0f4dfc4f01d29b2849ef78a6f8367371f7a379cf646f0c7eeaea60063ee35e301837ae30213caf49c2da31cae04009518d358c1ee55ea812008576ded183c135bb4433b34fd7360d698745f3d0bdd6b139c6868e3c2436a6039627464a60064262adbe3ca9e8c2263ce2a348c5ca87366202f8dd0a063d0944c63e5cd6856b26c351100e56e42ec0a54d395c2520a6ae345b974fd5c83d2e1403dbb6b231d1279b124bf744fcdacdee817b674248932722b103a787611054b37f000b4cc06e0862e8c013bf0fbab10e011aa84681ee80963d3dfa07af1d8a69f731a8c2eacf1629b85a8de64e2ecdd53abf9a86d3d2edfd3871f9e240a69233ff452833d435c1e47279683eb4617f3d784c03c5f711d31720a8e727d227a914b368f4af1063a6c45aaccdf470c0938c9a8d2ba7f105cc782721e0fef214a01a6cdb7b8a7ee710c0c6848b264a94b8519b5f060c77a9548baff91a2d98bc9aa1f86d55bc02d7bd780b24bbcaf532899d6c58f72132ca3476228db04316e670f02d541c18b4457e722877c3b7a3e67992b6ee0e3e72b6ff9bdda4b512008867ef44cb7bd9092ecfa8606366c380cd16570aa97337d86cba3eaca8809cc6bbbdc8472a5545430a8ce10ed7b780bb4ab366cf4c696533bad1bc03ab5aa14507fef79da134562ad45e94d89016561db3e6d4d82017ae9dc9226035481d18beb97c931ca0d2cfb82627d146785dd7a152e76207c1c0a0dee1323254ab18eb0a3cf5be3086b24740048c4b0e0b400b4a865df77932d9a4504b01348ce5aefcd82b2001210a8a8ae113ab9b6f6b5774a2adcea21c86dea95b2ec823ca420a30fa3f151c17b44586757b2b253155ce017e85189a817d4a7ff73783f44c83f9d0c257d9f30069c3bd15c2699ef9d2ee0b1ebcadd8e88003e49473f39fce6fa5a31de867bd95f20daf7787bddf3c29eb2c1d452318cc89f6b78a61253c691c0f6d76d8e77b6140e018cd6be336209bd591d84668666e30d4231acaded6e87aff0ddbfc04450e1c843ed86b2e0087117927d753556d635f00140a8211167132445ae25b4641526c39ea6d3f8f441c69c8c4f914922a1915d25674582a40ebc30e8532e477cef39470908c5a8df77f8024e78f818fc14d9397ba606aa3031d9b513257d214f84573103e71adaa23b56baa1b9da1438e8d3297ebb5fc8e1dc8ea8442505d941916b42859b73ab248336e6d7f6ebc4bda602cdd835b350f75ce6017dd2a87cbd0fa6c431a239052734a703cfb13fda51205fe1e40aac1e05038f247546ad51b2734cb9d11307b7bf545784d7010c2cd8bbb543c364e81c340231403ca6bc7f6152ff65654adcf98329e54f5ca4bd3f956d670fc471ccd372e3418d89022ab35758a3c77277330b13cb5301271b8bd54d1c2714017873592d4735691a3a13c6a11c209d7655f02fb741a53419e2969b1532016aedc6b8d08b] */