search
HomeBackend DevelopmentPython Tutorial怎么利用爬虫爬取QQ空间中设置了权限的无法正常访问的内容?

怎么利用爬虫爬取QQ空间中设置了权限的无法正常访问的内容?比如很多人的空间不允许别人访问,或者有些相册不允许别人访问

回复内容:

你把 『利用爬虫爬取』 这个定语去掉,能做到,再去考虑 『利用爬虫爬取』 这个问题。 任何情况下,计算机程序都只可以做它的创造者会做的事情,只是大多数情况下比那个创造它的人做的更快、更不易出错。
意味着,如果你可以在不知道加密相册的问题的答案的情况下进入相册(如果鹅厂存在BUG且你成功钻了),那么你的爬虫也可以。 一看题主就是连爬虫都没入门的人……大家可以散了 围观这个回答,适时举报好的答案 简单的说,爬虫是用代码来模仿你的操作和浏览器的操作。
你如果可以有办法查看这些内容,你就可以用爬虫爬取了 :) 楼主放过你的意淫对象吧! 先占位,等我做出来了再答。
目前按照我的爬虫技术是觉得做不到的。为什么?
首先来看一下爬虫是这样的一个回事
对于QQ空间,而且是设置了权限的QQ空间,你是无法之间获取该空间主页的URL的(按我目前的python技术是这样)
比如下面的代码:
import urllib2
import re

url = 'http://news.bioon.com/article/xxxxx'
#由于设置了权限,这个URL无法获取的。


headers = {
		'Referer':'http://news.bioon.com/article/xxxxx',
		'User-Agent':'AppleWebKit/537.36 (KHTML, like Gecko)'
		}

request = urllib2.Request(url,headers=headers)
response = urllib2.urlopen(request)
html = response.read()

这个我知道,但是只能看到一部分,一个不懂程序的人,发现的。
我发现在我回答这个问题后腾讯把这个漏洞封了 盗取对方的 QQ 账号,进而获取网页。
侵入网站后台,进而获取网页。
都是违法的,所以能做就做。 貌似可以看看对方空间的照片还是行的,不知道现在行不行(⊙o⊙)…
本来想说一下的
不过看到连问题都提错了,最恨装逼的人了,我打游戏去 了。(⊙o⊙)…
匿名了,万一被误解成大神就不好,灌点水哈

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
How do you slice a Python array?How do you slice a Python array?May 01, 2025 am 12:18 AM

The basic syntax for Python list slicing is list[start:stop:step]. 1.start is the first element index included, 2.stop is the first element index excluded, and 3.step determines the step size between elements. Slices are not only used to extract data, but also to modify and invert lists.

Under what circumstances might lists perform better than arrays?Under what circumstances might lists perform better than arrays?May 01, 2025 am 12:06 AM

Listsoutperformarraysin:1)dynamicsizingandfrequentinsertions/deletions,2)storingheterogeneousdata,and3)memoryefficiencyforsparsedata,butmayhaveslightperformancecostsincertainoperations.

How can you convert a Python array to a Python list?How can you convert a Python array to a Python list?May 01, 2025 am 12:05 AM

ToconvertaPythonarraytoalist,usethelist()constructororageneratorexpression.1)Importthearraymoduleandcreateanarray.2)Uselist(arr)or[xforxinarr]toconvertittoalist,consideringperformanceandmemoryefficiencyforlargedatasets.

What is the purpose of using arrays when lists exist in Python?What is the purpose of using arrays when lists exist in Python?May 01, 2025 am 12:04 AM

ChoosearraysoverlistsinPythonforbetterperformanceandmemoryefficiencyinspecificscenarios.1)Largenumericaldatasets:Arraysreducememoryusage.2)Performance-criticaloperations:Arraysofferspeedboostsfortaskslikeappendingorsearching.3)Typesafety:Arraysenforc

Explain how to iterate through the elements of a list and an array.Explain how to iterate through the elements of a list and an array.May 01, 2025 am 12:01 AM

In Python, you can use for loops, enumerate and list comprehensions to traverse lists; in Java, you can use traditional for loops and enhanced for loops to traverse arrays. 1. Python list traversal methods include: for loop, enumerate and list comprehension. 2. Java array traversal methods include: traditional for loop and enhanced for loop.

What is Python Switch Statement?What is Python Switch Statement?Apr 30, 2025 pm 02:08 PM

The article discusses Python's new "match" statement introduced in version 3.10, which serves as an equivalent to switch statements in other languages. It enhances code readability and offers performance benefits over traditional if-elif-el

What are Exception Groups in Python?What are Exception Groups in Python?Apr 30, 2025 pm 02:07 PM

Exception Groups in Python 3.11 allow handling multiple exceptions simultaneously, improving error management in concurrent scenarios and complex operations.

What are Function Annotations in Python?What are Function Annotations in Python?Apr 30, 2025 pm 02:06 PM

Function annotations in Python add metadata to functions for type checking, documentation, and IDE support. They enhance code readability, maintenance, and are crucial in API development, data science, and library creation.

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment