首页 \ 问答 \ OpenID - 获取用户信息?(OpenID — getting user information?)

OpenID - 获取用户信息?(OpenID — getting user information?)

我想知道是否有可能除了Google的电子邮件之外请求更多信息并获取用户的姓名?

我正在使用JanRain OpenID PHP脚本。

谢谢


I am wondering if it is possible to request more information besides email from Google and get the name of the user also?

Am using JanRain OpenID PHP script.

Thank you


原文:https://stackoverflow.com/questions/665122
更新时间:2023-10-25 08:10

最满意答案

在Unix系统中,当使用套接字进行多播时,您应该绑定到INADDR_ANY,而不是接口。

由接口进行多播过滤(即不接收来自指定接口以外的其他接口的mcast)已经到位,因为您正确填写了imr_interface。


So, in the end a little system configuration and bugfixing went a long way:

a) As root, I'd had to do the following to disable the reverse packet filter: echo 0 > /proc/sys/net/ipv4/conf/all/rp_filter + The same for ethX.

b) Add a bogus route for the ethX (route add -net 224.0.0.0. netmask 224.0.0.0 ethX)

c) Bind the socket to the to-be-joined group's IP (otherwise any subsequent socket would get all packets from all groups I joined on that particular port).

d) Set the interface member of the ip_mreq struct to the IP of the adapter we're receiving on.

And then all was fine and dandy, test runs fast & smooth (pulling 125 multicast transport streams @ around 800-900 mbit - sure this can be smarter, but still). Thanks for all the pointers.

相关问答

更多
  • 您的网络堆栈将定期发送IGMP消息。 您的网络上的交换机可能使用IGMP监听来确定您的计算机需要哪些(如果有)多播消息。 (这是为了避免由于他们没有请求的流量而在主机上施加过多的负载。) 当您的笔记本电脑休眠时,它将停止发送定期消息,确认其对某些多播流量的兴趣。 您的交换机会注意到这一点并停止将流量发送到您的笔记本电脑 我想你需要发现你的笔记本电脑何时从休眠状态恢复并重新添加成员资格到多播组。 我过去通过使用控制代码SIO_ADDRESS_LIST_CHANGE调用WSAIoctl来完成此操作(以及启用/禁 ...
  • 您没有正确测试select()错误。 您可以在其中一个中收到错误。 应该recieve == -1 || sent == -1测试recieve == -1 || sent == -1 recieve == -1 || sent == -1 ,但我无法想象你为什么要两次调用select() ,甚至为什么你使用两个套接字。 你只需要一个选择。 试试这种方式,你可能会赶走其他一些错误。 注意:由于您创建套接字的顺序,您不能依赖第二个套接字描述符大于第一个套接字描述符。您必须测试或使用max() 。 You ar ...
  • 在Unix系统中,当使用套接字进行多播时,您应该绑定到INADDR_ANY,而不是接口。 由接口进行多播过滤(即不接收来自指定接口以外的其他接口的mcast)已经到位,因为您正确填写了imr_interface。 So, in the end a little system configuration and bugfixing went a long way: a) As root, I'd had to do the following to disable the reverse packet fil ...
  • 由于您是在互联网上尝试客户端,因此所有互联网新工作都代表着可能的全部原因。 这里没有简单的调试方法。 可能的原因当然可能是软件错误,但也可能是您和远程服务器之间的一些中间网络配置。 您应该使用您和服务器之间的良好wireshark或命令行tcpdump捕获udp流量,并检查您是否停止发送数据包或服务器是否正在停止接收它们。 如果您发送数据包但服务器没有收到它们(服务器上的tcpdump ),那么网络上有一些东西决定过滤您的数据包。 如果它不在服务器上(例如防火墙规则对数据包进行速率限制或类似的事情),那么在 ...
  • 在网络编程中,空地址字符串表示所有配置的接口 但是,如果指定了IP地址,则套接字将只在具有指定IP地址的接口上侦听。 In network programming empty address string denotes all configured interfaces. If however IP address is specified, socket will only listen on interface with specified IP address.
  • $binded = socket_bind($socket, '127.0.0.1', 6073); 应该 $binded = socket_bind($socket, '0.0.0.0', 6073); 否则你只会收集来自本地主机的数据包。 $binded = socket_bind($socket, '127.0.0.1', 6073); Should be $binded = socket_bind($socket, '0.0.0.0', 6073); Or else you will onl ...
  • 在服务器端,一个套接字用于发送多播,另一个用于接收来自客户端的回复。 当然不。 在客户端,一个用于接收数据的套接字和另一个用于回复服务器的套接字。 当然不。 对等方总是希望回复IP:端口请求来自。 如果添加另一个端口,则会增加无限的配置难度。 如果你只使用一个端口,这很容易。 为此,每个进程使用两个端口没有性能或架构原因。 On server side one socket for sending multicast and another for receiving replies from client ...
  • 这很可能是您的发送和接收线程之间的竞争 - 您在接收器加入组之前发送第一个数据包。 这解释了为什么它适用于超时。 This most likely is a race between your sending and receiving threads - you send the first packet before the receiver joins the group. This explains why it works with a timeout.
  • 它应该工作正常。 只要你绑定到IN6ADDR_ANY ,然后加入组播组,你应该能够发送和接收单播数据包没有问题。 使用多播时,绑定到IN6ADDR_ANY (或IPv4的INADDR_ANY )很重要。 如果绑定到特定接口,则会破坏Linux系统上的多播。 It should work fine. As long as you bind to IN6ADDR_ANY, then join the multicast groups, you should be able to send and receive ...
  • 不,你不能将套接字绑定到两个端口,每个端口需要一个套接字。 No, you can't bind a socket to 2 ports, you need a socket per port.

相关文章

更多

最新问答

更多
  • h2元素推动其他h2和div。(h2 element pushing other h2 and div down. two divs, two headers, and they're wrapped within a parent div)
  • 创建一个功能(Create a function)
  • 我投了份简历,是电脑编程方面的学徒,面试时说要培训三个月,前面
  • PDO语句不显示获取的结果(PDOstatement not displaying fetched results)
  • Qt冻结循环的原因?(Qt freezing cause of the loop?)
  • TableView重复youtube-api结果(TableView Repeating youtube-api result)
  • 如何使用自由职业者帐户登录我的php网站?(How can I login into my php website using freelancer account? [closed])
  • SQL Server 2014版本支持的最大数据库数(Maximum number of databases supported by SQL Server 2014 editions)
  • 我如何获得DynamicJasper 3.1.2(或更高版本)的Maven仓库?(How do I get the maven repository for DynamicJasper 3.1.2 (or higher)?)
  • 以编程方式创建UITableView(Creating a UITableView Programmatically)
  • 如何打破按钮上的生命周期循环(How to break do-while loop on button)
  • C#使用EF访问MVC上的部分类的自定义属性(C# access custom attributes of a partial class on MVC with EF)
  • 如何获得facebook app的publish_stream权限?(How to get publish_stream permissions for facebook app?)
  • 如何防止调用冗余函数的postgres视图(how to prevent postgres views calling redundant functions)
  • Sql Server在欧洲获取当前日期时间(Sql Server get current date time in Europe)
  • 设置kotlin扩展名(Setting a kotlin extension)
  • 如何并排放置两个元件?(How to position two elements side by side?)
  • 如何在vim中启用python3?(How to enable python3 in vim?)
  • 在MySQL和/或多列中使用多个表用于Rails应用程序(Using multiple tables in MySQL and/or multiple columns for a Rails application)
  • 如何隐藏谷歌地图上的登录按钮?(How to hide the Sign in button from Google maps?)
  • Mysql左连接旋转90°表(Mysql Left join rotate 90° table)
  • dedecms如何安装?
  • 在哪儿学计算机最好?
  • 学php哪个的书 最好,本人菜鸟
  • 触摸时不要突出显示表格视图行(Do not highlight table view row when touched)
  • 如何覆盖错误堆栈getter(How to override Error stack getter)
  • 带有ImageMagick和许多图像的GIF动画(GIF animation with ImageMagick and many images)
  • USSD INTERFACE - > java web应用程序通信(USSD INTERFACE -> java web app communication)
  • 电脑高中毕业学习去哪里培训
  • 正则表达式验证SMTP响应(Regex to validate SMTP Responses)