- 博客(1)
- 资源 (5)
- 收藏
- 关注
原创 (Spring boot 2.x 版本)Spring Cloud Eureka 注册中心开启用户权限验证
当我们配置完Spring Cloud Eureka 注册中心的时候,默认访问首页直接进入注册中心。 这样不管是谁,都可以直接进入太不安全,如果是在内网还好一点,如在外网,则把你的所有服务都暴露在外,非常不安全。 好在Spring Cloud 已近为我们考虑到了这些,而且也有了解决方案,而且非常简单 第一步:增加spring-boot-starter-security 依赖 <...
2019-04-22 09:14:47 952 1
simplewebrtc.js webrtc网页视频开发帮助工具
网页视频开发 webrtc
;(function () {
var logger = {
log: function (){},
warn: function (){},
error: function (){}
};
// normalize environment
var RTCPeerConnection = null,
getUserMedia = null,
attachMediaStream = null,
reattachMediaStream = null,
browser = null,
webRTCSupport = true;
if (navigator.mozGetUserMedia) {
logger.log("This appears to be Firefox");
browser = "firefox";
// The RTCPeerConnection object.
RTCPeerConnection = mozRTCPeerConnection;
// The RTCSessionDescription object.
RTCSessionDescription = mozRTCSessionDescription;
// The RTCIceCandidate object.
RTCIceCandidate = mozRTCIceCandidate;
// Get UserMedia (only difference is the prefix).
// Code from Adam Barth.
getUserMedia = navigator.mozGetUserMedia.bind(navigator);
// Attach a media stream to an element.
attachMediaStream = function(element, stream) {
element.mozSrcObject = stream;
element.play();
};
reattachMediaStream = function(to, from) {
to.mozSrcObject = from.mozSrcObject;
to.play();
};
// Fake get{Video,Audio}Tracks
MediaStream.prototype.getVideoTracks = function() {
return [];
};
MediaStream.prototype.getAudioTracks = function() {
return [];
};
} else if (navigator.webkitGetUserMedia) {
browser = "chrome";
// The RTCPeerConnection object.
RTCPeerConnection = webkitRTCPeerConnection;
// Get UserMedia (only difference is the prefix).
// Code from Adam Barth.
getUserMedia = navigator.webkitGetUserMedia.bind(navigator);
// Attach a media stream to an element.
attachMediaStream = function(element, stream) {
element.autoplay = true;
element.src = webkitURL.createObjectURL(stream);
};
reattachMediaStream = function(to, from) {
to.src = from.src;
};
// The representation of tracks in a stream is changed in M26.
// Unify them for e
2013-03-27
图片处理工具,图片切割,图片缩放,图片黑白处理
图片切割,图片缩放,图片黑白处理,gif图片制作,gif图片分解,等图片处理工具类
在 OperateImage 类中包含所有工具方法
2012-10-21
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人