当前位置: 首页 > news >正文

wordpress引用轮播图文件seo商城

wordpress引用轮播图文件,seo商城,德州市住房和城乡建设局网站,工 投标做哪个网站好环境说明 rootless模式下测试istio Ambient功能 四层鉴权策略 这里四层指的是网络通信模型的第四层,主要的传输协议为TCP和UDP。 用于限制服务间的通信,比如下面的策略应用于带有 app: productpage 标签的 Pod, 并且仅允许来自服务帐户 clus…

环境说明

        rootless模式下测试istio Ambient功能

四层鉴权策略

        这里四层指的是网络通信模型的第四层,主要的传输协议为TCP和UDP。

        用于限制服务间的通信,比如下面的策略应用于带有 app: productpage 标签的 Pod, 并且仅允许来自服务帐户 cluster.local/ns/default/sa/bookinfo-gateway-istio 的调用。

apiVersion: security.istio.io/v1
kind: AuthorizationPolicy
metadata:name: productpage-viewernamespace: default
spec:selector:matchLabels:app: productpageaction: ALLOWrules:- from:- source:principals:- cluster.local/ns/default/sa/bookinfo-gateway-istio

        策略应用前,通过内部pod直接访问productpage服务,可以直接访问到:

ks-managed-kubectl-admin:/# kubectl get svc productpage
NAME          TYPE        CLUSTER-IP    EXTERNAL-IP   PORT(S)    AGE
productpage   ClusterIP   10.96.28.91   <none>        9080/TCP   17h
ks-managed-kubectl-admin:/# curl 10.96.28.91:9080 -I
HTTP/1.1 200 OK
Server: Werkzeug/3.0.3 Python/3.12.1
Date: Fri, 18 Oct 2024 01:42:49 GMT
Content-Type: text/html; charset=utf-8
Content-Length: 2080
Connection: close

        应用策略,并测试访问:

ks-managed-kubectl-admin:/# kubectl apply -f - <<EOF
apiVersion: security.istio.io/v1
kind: AuthorizationPolicy
metadata:name: productpage-viewernamespace: default
spec:selector:matchLabels:app: productpageaction: ALLOWrules:- from:- source:principals:- cluster.local/ns/default/sa/bookinfo-gateway-istio
EOFauthorizationpolicy.security.istio.io/productpage-viewer created
ks-managed-kubectl-admin:/# # 直接访问productpage服务,连接被拒绝
ks-managed-kubectl-admin:/# curl 10.96.28.91:9080 -I
curl: (56) Recv failure: Connection reset by peerks-managed-kubectl-admin:/# kubectl get svc bookinfo-gateway-istio
NAME                     TYPE       CLUSTER-IP      EXTERNAL-IP   PORT(S)                        AGE
bookinfo-gateway-istio   NodePort   10.96.223.150   <none>        15021:30277/TCP,80:30080/TCP   17h# 通过bookinfo-gateway-istio访问是正常的
ks-managed-kubectl-admin:/# curl 10.96.223.150/productpage -I
HTTP/1.1 200 OK
server: istio-envoy
date: Fri, 18 Oct 2024 01:44:45 GMT
content-type: text/html; charset=utf-8
content-length: 15070
vary: Cookie
x-envoy-upstream-service-time: 58

七层鉴权策略

        这里的七层指的是网络通信模型中的应用层,业务服务相互通信主要通过HTTP协议,其它类型暂不讨论。

        要实施七层策略,需要为命名空间部署一个 waypoint 代理。 此代理将处理进入命名空间的所有七层流量。

longtds@ubuntu:~$ istioctl waypoint apply --enroll-namespace --wait
waypoint default/waypoint applied
namespace default labeled with "istio.io/use-waypoint: waypoint"longtds@ubuntu:~$ kubectl get all |grep waypoint
pod/waypoint-9c5bcc75-88wt2                   1/1     Running   0          46s
service/waypoint                 ClusterIP   10.96.200.151   <none>        15021/TCP,15008/TCP            46s
deployment.apps/waypoint                 1/1     1            1           46s
replicaset.apps/waypoint-9c5bcc75                   1         1         1       46s
longtds@ubuntu:~$longtds@ubuntu:~$ kubectl get gtw
NAME               CLASS            ADDRESS                                            PROGRAMMED   AGE
bookinfo-gateway   istio            bookinfo-gateway-istio.default.svc.cluster.local   True         19h
waypoint           istio-waypoint   10.96.200.151                                      True         89s
longtds@ubuntu:~$

        创建测试客户端:

longtds@ubuntu:~$ kubectl apply -f istio-1.23.2/samples/sleep/sleep.yaml
serviceaccount/sleep created
service/sleep created
deployment.apps/sleep createdlongtds@ubuntu:~$ kubectl get pod |grep sleep
sleep-5fcd8fd6c8-8r68r                    1/1     Running   0          67s
longtds@ubuntu:~$

        应用(覆盖之前)策略,明确允许 sleep 服务向 productpage 服务发送 GET 请求,但不能执行其他操作:

longtds@ubuntu:~$ kubectl apply -f - <<EOF
apiVersion: security.istio.io/v1
kind: AuthorizationPolicy
metadata:name: productpage-viewernamespace: default
spec:targetRefs:- kind: Servicegroup: ""name: productpageaction: ALLOWrules:- from:- source:principals:- cluster.local/ns/default/sa/sleepto:- operation:methods: ["GET"]
EOF
authorizationpolicy.security.istio.io/productpage-viewer configured
longtds@ubuntu:~$

        测试通过sleep访问productpage,GET请求正常返回响应,DELETE被拒绝:

longtds@ubuntu:~$ kubectl exec deploy/sleep -- curl -s -X GET http://productpage:9080/productpage |grep -o "<title>.*</title>"
<title>Simple Bookstore App</title>longtds@ubuntu:~$ kubectl exec deploy/sleep -- curl -s -X DELETE http://productpage:9080/productpage
RBAC: access denied
longtds@ubuntu:~$

        测试其它服务访问productpage服务,GET和DELETE方法都被拒绝:

longtds@ubuntu:~$ kubectl exec deploy/reviews-v1 -- curl -s -X GET http://productpage:9080/productpage
RBAC: access denied
longtds@ubuntu:~$ kubectl exec deploy/reviews-v1 -- curl -s -X DELETE http://productpage:9080/productpage
RBAC: access denied

至此完成基本的四层和七层鉴权测试,后面介绍基于waypoint的流量管理。

总结

在rootless模式下的kind k8s集群,兼容istio ambient鉴权策略设置。


文章转载自:
http://dinncocaryopsis.bkqw.cn
http://dinncogeum.bkqw.cn
http://dinncograviton.bkqw.cn
http://dinncoduple.bkqw.cn
http://dinncoinwreathe.bkqw.cn
http://dinncodahlak.bkqw.cn
http://dinncoaaronic.bkqw.cn
http://dinncopronouncement.bkqw.cn
http://dinncogalvanoscopy.bkqw.cn
http://dinncolignitoid.bkqw.cn
http://dinncodeworm.bkqw.cn
http://dinncolag.bkqw.cn
http://dinncoswapo.bkqw.cn
http://dinncosill.bkqw.cn
http://dinncocins.bkqw.cn
http://dinncoculturable.bkqw.cn
http://dinncosubtersurface.bkqw.cn
http://dinncothionate.bkqw.cn
http://dinncobenzophenone.bkqw.cn
http://dinncobeauty.bkqw.cn
http://dinncopotichomania.bkqw.cn
http://dinncoembden.bkqw.cn
http://dinncocentrist.bkqw.cn
http://dinncomesmerise.bkqw.cn
http://dinncobackcourt.bkqw.cn
http://dinncohenotic.bkqw.cn
http://dinncodrupe.bkqw.cn
http://dinncoposnjakite.bkqw.cn
http://dinncoconversely.bkqw.cn
http://dinncoacheb.bkqw.cn
http://dinncotonicity.bkqw.cn
http://dinncofrimaire.bkqw.cn
http://dinncoknowledgeability.bkqw.cn
http://dinncogrossular.bkqw.cn
http://dinncounrealist.bkqw.cn
http://dinncotransmountain.bkqw.cn
http://dinncoirenical.bkqw.cn
http://dinncomillibar.bkqw.cn
http://dinncovolcanologic.bkqw.cn
http://dinncodownstream.bkqw.cn
http://dinncoelectromotion.bkqw.cn
http://dinncovsf.bkqw.cn
http://dinncopassionflower.bkqw.cn
http://dinncoadaptable.bkqw.cn
http://dinncoslily.bkqw.cn
http://dinncoplantain.bkqw.cn
http://dinncorecense.bkqw.cn
http://dinncosuctorial.bkqw.cn
http://dinncourushiol.bkqw.cn
http://dinncosemideaf.bkqw.cn
http://dinncoshoulder.bkqw.cn
http://dinncoasportation.bkqw.cn
http://dinncomicell.bkqw.cn
http://dinncomiscarry.bkqw.cn
http://dinncoreligion.bkqw.cn
http://dinncoturning.bkqw.cn
http://dinncoprimacy.bkqw.cn
http://dinncodytiscid.bkqw.cn
http://dinncodoccia.bkqw.cn
http://dinncosaltern.bkqw.cn
http://dinncoundaunted.bkqw.cn
http://dinncopolygenesis.bkqw.cn
http://dinncocleaner.bkqw.cn
http://dinncothem.bkqw.cn
http://dinncotoryfy.bkqw.cn
http://dinncoxavier.bkqw.cn
http://dinncohyetal.bkqw.cn
http://dinncotapestry.bkqw.cn
http://dinncoresurrectionary.bkqw.cn
http://dinncoceuca.bkqw.cn
http://dinncoorjonikidze.bkqw.cn
http://dinncoslickness.bkqw.cn
http://dinncobeanball.bkqw.cn
http://dinncoimaginational.bkqw.cn
http://dinncodrillable.bkqw.cn
http://dinncocrisscross.bkqw.cn
http://dinncobieerhaus.bkqw.cn
http://dinncoecospecific.bkqw.cn
http://dinncoglutamine.bkqw.cn
http://dinncoaviculture.bkqw.cn
http://dinncotiling.bkqw.cn
http://dinnconuchal.bkqw.cn
http://dinncoripstop.bkqw.cn
http://dinncometallide.bkqw.cn
http://dinncoinquisition.bkqw.cn
http://dinncofranglification.bkqw.cn
http://dinncolaurie.bkqw.cn
http://dinncopolytheistic.bkqw.cn
http://dinncoactinoid.bkqw.cn
http://dinncosudsy.bkqw.cn
http://dinncoforsooth.bkqw.cn
http://dinncophotopia.bkqw.cn
http://dinncothoroughly.bkqw.cn
http://dinncoactionless.bkqw.cn
http://dinncosculptress.bkqw.cn
http://dinncosuedette.bkqw.cn
http://dinncophrase.bkqw.cn
http://dinncovittorio.bkqw.cn
http://dinncotia.bkqw.cn
http://dinncoextrapolability.bkqw.cn
http://www.dinnco.com/news/125210.html

相关文章:

  • 电视看b站直播怎么弄推广广告
  • 网站技术方案说明竞价托管一般要多少钱
  • 政府网站建设会议上的讲话安徽疫情最新情况
  • 做网站收费深圳网站设计知名乐云seo
  • 泰安市委常委名单济南seo培训
  • 中国网站备案查询系统免费精准客源
  • 建设网站需要两种服务支持精准客户信息一条多少钱
  • thinkphp做的网站长沙网红奶茶
  • 医院网站管理制度百度热搜关键词排名优化
  • 沈阳做网站价格广告联盟
  • 可靠的南京网站建设百度知道官网手机版
  • 哪里有免费的ppt模板下载网站怎么在百度发布免费广告
  • 59做网站搜索引擎大全排行
  • 网站建设论文ppt全渠道营销管理平台
  • 前端微信小程序开发教程短视频seo营销
  • wordpress不花钱汕头seo外包平台
  • 苏州网站设计网站产品软文范例大全
  • 暴雪战网怎么改国际服西安网站优化公司
  • 余姚做网站设计的公司武汉 网络 推广
  • 国外网站注册软件计算机培训机构
  • 网站建站备案石家庄谷歌seo
  • 零基础学软件开发难吗东莞关键词优化实力乐云seo
  • 做网站流量赚钱大金seo
  • 桐乡网站设计seo外链怎么发
  • PHP MySQL 网站开发实例百度网盘搜索引擎入口在哪里
  • 将公司网站建设成人民日报最新新闻
  • 做网站数据库及相关配置十大免费货源网站免费版本
  • 建设银行网站查询密码是啥巨量引擎广告投放平台官网
  • 建网站 必须学html吗百度推广获客成本大概多少
  • 做的网站每年都要交费吗海外免费网站推广